Skip to content

Commit 53789e1

Browse files
committed
Using If-Modified-Since with a date more recent than LastModified should also return 304.
1 parent 4e095f7 commit 53789e1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Cache.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public function __invoke(RequestInterface $request, ResponseInterface $response,
6363
$lastModified = strtotime($lastModified);
6464
}
6565
$ifModifiedSince = $request->getHeader('If-Modified-Since');
66-
if ($ifModifiedSince && $lastModified === strtotime($ifModifiedSince)) {
66+
if ($ifModifiedSince && $lastModified <= strtotime($ifModifiedSince)) {
6767
return $response->withStatus(304);
6868
}
6969
}

0 commit comments

Comments
 (0)