summary refs log tree commit diff
path: root/synapse/handlers/profile.py
diff options
context:
space:
mode:
authorMathieu Velten <mathieuv@matrix.org>2023-07-27 15:45:05 +0200
committerGitHub <noreply@github.com>2023-07-27 15:45:05 +0200
commita719b703d9bd0dade2565ddcad0e2f3a7a9d4c37 (patch)
tree3015ecadb093ac002aa6b4a73b4e6a994e188c42 /synapse/handlers/profile.py
parentUpdate PyYAML to 6.0.1 (#16011) (diff)
downloadsynapse-a719b703d9bd0dade2565ddcad0e2f3a7a9d4c37.tar.xz
Fix 404 on /profile when the display name is empty but not the avatar (#16012)
Diffstat (limited to 'synapse/handlers/profile.py')
-rw-r--r--synapse/handlers/profile.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/handlers/profile.py b/synapse/handlers/profile.py
index a7f8c5e636..c7fe101cd9 100644
--- a/synapse/handlers/profile.py
+++ b/synapse/handlers/profile.py
@@ -68,7 +68,7 @@ class ProfileHandler:
 
         if self.hs.is_mine(target_user):
             profileinfo = await self.store.get_profileinfo(target_user)
-            if profileinfo.display_name is None:
+            if profileinfo.display_name is None and profileinfo.avatar_url is None:
                 raise SynapseError(404, "Profile was not found", Codes.NOT_FOUND)
 
             return {