diff options
author | Andrew Godwin | 2022-12-15 00:35:04 -0700 |
---|---|---|
committer | Andrew Godwin | 2022-12-15 00:43:39 -0700 |
commit | 69f1b3168ac3f29fc4bafba0418769248b10062a (patch) | |
tree | 23b84b73be1f791d20c844ab4435152f8b182804 /core/uris.py | |
parent | e0053b69ded06ef246db6239baeea87617a2621c (diff) | |
download | takahe-69f1b3168ac3f29fc4bafba0418769248b10062a.tar.gz takahe-69f1b3168ac3f29fc4bafba0418769248b10062a.tar.bz2 takahe-69f1b3168ac3f29fc4bafba0418769248b10062a.zip |
Improve cacheability
Diffstat (limited to 'core/uris.py')
-rw-r--r-- | core/uris.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/uris.py b/core/uris.py index 2800fd4..81f53b6 100644 --- a/core/uris.py +++ b/core/uris.py @@ -1,7 +1,7 @@ from urllib.parse import urljoin from django.conf import settings -from django.templatetags.static import static +from django.contrib.staticfiles.storage import staticfiles_storage class RelativeAbsoluteUrl: @@ -41,7 +41,7 @@ class StaticAbsoluteUrl(RelativeAbsoluteUrl): """ def __init__(self, path: str): - static_url = static(path) + static_url = staticfiles_storage.url(path) if "://" in static_url: super().__init__(static_url) else: |