Skip to content

Commit

Permalink
Better caching
Browse files Browse the repository at this point in the history
Based on @trinity-1686a's patch: #786 (comment)
  • Loading branch information
elegaanz committed Jun 25, 2020
1 parent 581a97e commit 45cebcf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/template_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ impl<'r> Responder<'r> for Ructe {
let etag = format!("{:x}", hasher.finish());
if r.headers()
.get("If-None-Match")
.any(|s| s[1..s.len() - 1] == etag)
.any(|s| s[1..s.len() - 1] == etag || s[3..s.len() - 1] == etag)
{
Response::build()
.status(Status::NotModified)
Expand Down

0 comments on commit 45cebcf

Please sign in to comment.