Skip to content

Commit

Permalink
Merge pull request yiisoft#6641 from DaSourcerer/HttpCache-etag-zero-…
Browse files Browse the repository at this point in the history
…padding-removal

Strip zero padding from ETag strings
  • Loading branch information
qiangxue committed Dec 24, 2014
2 parents 6e46ca0 + e288c54 commit 840fe73
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions framework/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Yii Framework 2 Change Log
- Enh #6467: `ActiveForm` will scroll to the nearest visible element when the first error input is hidden (newartix)
- Enh #6488: Support changing `yii\base\Theme::basePath` during runtime (qiangxue)
- Chg #6427: In case of invalid route web application now throws exception with "Page not found" instead of "Invalid Route" (cebe, samdark)
- Chg #6641: removed zero padding from ETag strings (DaSourcerer)

2.0.1 December 07, 2014
-----------------------
Expand Down
2 changes: 1 addition & 1 deletion framework/filters/HttpCache.php
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,6 @@ protected function sendCacheControlHeader()
*/
protected function generateEtag($seed)
{
return '"' . base64_encode(sha1($seed, true)) . '"';
return '"' . rtrim(base64_encode(sha1($seed, true)), '=') . '"';
}
}

0 comments on commit 840fe73

Please sign in to comment.