summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Löthberg <johannes@kyriasis.com>2018-01-02 09:14:41 +0100
committerJelle van der Waa <jelle@vdwaa.nl>2018-04-08 12:51:19 +0200
commit48ff9f907aebd90fb4011a45dc5e12dc45beadf2 (patch)
treeb88d9bc3c9a4b88e1d25afc6bdba78e02e8d4b9f
parentf442bc42f7dd8fe95b54d9768bca65ac98796397 (diff)
downloadarchweb-48ff9f907aebd90fb4011a45dc5e12dc45beadf2.tar.gz
archweb-48ff9f907aebd90fb4011a45dc5e12dc45beadf2.zip
main/storage: Switch from Cached to ManifestStaticFilesStorage
Django explicitly recommends against using CachedStaticFilesStorage, partially because it performs worse. It also breaks our tests with our Minified subclassing of it. Signed-off-by: Johannes Löthberg <johannes@kyriasis.com>
-rw-r--r--main/storage.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/main/storage.py b/main/storage.py
index 62e94ef7..83d84c4b 100644
--- a/main/storage.py
+++ b/main/storage.py
@@ -1,12 +1,12 @@
import cssmin
import jsmin
-from django.contrib.staticfiles.storage import CachedStaticFilesStorage
+from django.contrib.staticfiles.storage import ManifestStaticFilesStorage
from django.core.files.base import ContentFile
from django.utils.encoding import smart_str
-class MinifiedStaticFilesStorage(CachedStaticFilesStorage):
+class MinifiedStaticFilesStorage(ManifestStaticFilesStorage):
"""
A static file system storage backend which minifies the hashed
copies of the files it saves. It currently knows how to process