Skip to content
This repository was archived by the owner on Nov 22, 2018. It is now read-only.

Commit 8487bf0

Browse files
joostvanhasselpakrym
authored andcommitted
14.28 If-Unmodified-Since - Incorrect condition
14.28 If-Unmodified-Since had a condition on ifModifiedSince, which could be undefined. Should be ifUnmodifiedSince
1 parent 353219d commit 8487bf0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Microsoft.AspNetCore.StaticFiles/StaticFileContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ private void ComputeIfModifiedSince()
210210

211211
// 14.28 If-Unmodified-Since
212212
var ifUnmodifiedSince = _requestHeaders.IfUnmodifiedSince;
213-
if (ifUnmodifiedSince.HasValue && ifModifiedSince <= now)
213+
if (ifUnmodifiedSince.HasValue && ifUnmodifiedSince <= now)
214214
{
215215
bool unmodified = ifUnmodifiedSince >= _lastModified;
216216
_ifUnmodifiedSinceState = unmodified ? PreconditionState.ShouldProcess : PreconditionState.PreconditionFailed;

0 commit comments

Comments
 (0)