UI: fix main user link on user pages to be external

pull/984/head
Ryan Barrett 2024-04-30 16:13:31 -07:00
rodzic 50dce84d68
commit 0ddb1255f4
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 6BE31FDF4776E9D4
1 zmienionych plików z 2 dodań i 1 usunięć

Wyświetl plik

@ -611,7 +611,8 @@ class User(StringIdModel, metaclass=ProtocolUserMeta):
instead of external account
"""
url = (self.user_page_path()
if self.enabled_protocols or self.LABEL == 'web' or self.direct
if maybe_internal_link and (self.enabled_protocols
or self.LABEL == 'web' or self.direct)
else self.web_url())
pic = self.profile_picture()
img = f'<img src="{pic}" class="profile">' if pic else ''