Skip to content

Commit

Permalink
Fix cache key not depending on chosen_algorithm (#54)
Browse files Browse the repository at this point in the history
  • Loading branch information
xmcp authored Oct 6, 2024
1 parent de66430 commit edbe5fb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion flask_compress/flask_compress.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def after_request(self, response):
response.direct_passthrough = False

if self.cache is not None:
key = self.cache_key(request)
key = (chosen_algorithm, self.cache_key(request))
compressed_content = self.cache.get(key)
if compressed_content is None:
compressed_content = self.compress(app, response, chosen_algorithm)
Expand Down

0 comments on commit edbe5fb

Please sign in to comment.