Skip to content

Commit

Permalink
0 - also indicates no modification date is available
Browse files Browse the repository at this point in the history
  • Loading branch information
markt-asf committed Dec 13, 2024
1 parent 7d19629 commit fd2ad0a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions java/org/apache/catalina/servlets/DefaultServlet.java
Original file line number Diff line number Diff line change
Expand Up @@ -2242,7 +2242,7 @@ protected boolean checkIfModifiedSince(HttpServletRequest request, HttpServletRe
}

long resourceLastModified = resource.getLastModified();
if (resourceLastModified <= -1) {
if (resourceLastModified <= 0) {
// MUST ignore if the resource does not have a modification date available.
return true;
}
Expand Down Expand Up @@ -2374,7 +2374,7 @@ protected boolean checkIfUnmodifiedSince(HttpServletRequest request, HttpServlet
WebResource resource) throws IOException {

long resourceLastModified = resource.getLastModified();
if (resourceLastModified <= -1) {
if (resourceLastModified <= 0) {
// MUST ignore if the resource does not have a modification date available.
return true;
}
Expand Down

0 comments on commit fd2ad0a

Please sign in to comment.