diff options
author | Andrew Godwin | 2022-12-12 07:32:35 -0700 |
---|---|---|
committer | Andrew Godwin | 2022-12-12 11:56:49 -0700 |
commit | 5bc9ff39ac4f4a4b0d43066bce9cfde0397f3388 (patch) | |
tree | 4d4403c9f9c4d41c4db5d28e5a629056051aad0c /users/models | |
parent | 8ffe4bc1453660c1f211496074ebcc68c924327e (diff) | |
download | takahe-5bc9ff39ac4f4a4b0d43066bce9cfde0397f3388.tar.gz takahe-5bc9ff39ac4f4a4b0d43066bce9cfde0397f3388.tar.bz2 takahe-5bc9ff39ac4f4a4b0d43066bce9cfde0397f3388.zip |
Fix static file URLs
Diffstat (limited to 'users/models')
-rw-r--r-- | users/models/identity.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/users/models/identity.py b/users/models/identity.py index 1ece0fd..1239ca1 100644 --- a/users/models/identity.py +++ b/users/models/identity.py @@ -7,7 +7,6 @@ import urlman from asgiref.sync import async_to_sync, sync_to_async from django.db import IntegrityError, models from django.template.defaultfilters import linebreaks_filter -from django.templatetags.static import static from django.utils import timezone from django.utils.functional import lazy @@ -17,7 +16,7 @@ from core.ld import canonicalise, format_ld_date, get_list, media_type_from_file from core.models import Config from core.signatures import HttpSignature, RsaKeys from core.uploads import upload_namer -from core.uris import AutoAbsoluteUrl, RelativeAbsoluteUrl +from core.uris import AutoAbsoluteUrl, RelativeAbsoluteUrl, StaticAbsoluteUrl from stator.models import State, StateField, StateGraph, StatorModel from users.models.domain import Domain from users.models.system_actor import SystemActor @@ -156,7 +155,7 @@ class Identity(StatorModel): elif self.icon_uri: return AutoAbsoluteUrl(f"/proxy/identity_icon/{self.pk}/") else: - return RelativeAbsoluteUrl(static("img/unknown-icon-128.png")) + return StaticAbsoluteUrl("img/unknown-icon-128.png") def local_image_url(self) -> RelativeAbsoluteUrl | None: """ |