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 22e8605 commit 9bd3381
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 @@ -2183,7 +2183,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 @@ -2315,7 +2315,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 9bd3381

Please sign in to comment.