diff --git a/bskyweb/templates/post.html b/bskyweb/templates/post.html index ff21aaca14..5c7c844e61 100644 --- a/bskyweb/templates/post.html +++ b/bskyweb/templates/post.html @@ -62,7 +62,12 @@ "@type": "DiscussionForumPosting", "author": { "@type": "Person", + {%- if postView.Author.DisplayName %} "name": "{{ postView.Author.DisplayName }}", + "alternateName": "@{{ postView.Author.Handle }}", + {% else %} + "name": "@{{ postView.Author.Handle }}", + {% endif -%} "url": "https://bsky.app/profile/{{ postView.Author.Handle }}" }, {%- if postText %} diff --git a/bskyweb/templates/profile.html b/bskyweb/templates/profile.html index bb552ef47d..b4be429289 100644 --- a/bskyweb/templates/profile.html +++ b/bskyweb/templates/profile.html @@ -59,8 +59,12 @@ "dateCreated": "{{ profileView.CreatedAt }}", "mainEntity": { "@type": "Person", + {%- if profileView.DisplayName %} "name": "{{ profileView.DisplayName }}", "alternateName": "@{{ profileView.Handle }}", + {% else %} + "name": "@{{ profileView.Handle }}", + {% endif -%} "identifier": "{{ profileView.Did }}", "description": "{{ profileView.Description }}", "image": "{{ profileView.Avatar }}",