Skip to content

Commit

Permalink
Add non manifest strict storage
Browse files Browse the repository at this point in the history
  • Loading branch information
cuducos committed Sep 13, 2018
1 parent 9fa0cc6 commit d4a5126
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions jarbas/storages.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
from whitenoise.storage import CompressedManifestStaticFilesStorage


class WhiteNoiseStaticFilesStorage(CompressedManifestStaticFilesStorage):
manifest_strict = False

def hashed_name(self, *args, **kwargs):
"""Skip hashing app.js because it is included in the container volume
after collectstatic runs."""
name, *_ = *args
if name.endswith('/static/app.js'):
return name

name = super(WhiteNoiseStaticFilesStorage, self).hashed_name(*args, **kwargs)

0 comments on commit d4a5126

Please sign in to comment.