diff --git a/.github/workflows/xlog.yml b/.github/workflows/xlog.yml index c5640afb..b5e56094 100644 --- a/.github/workflows/xlog.yml +++ b/.github/workflows/xlog.yml @@ -43,7 +43,7 @@ jobs: --sidebar=false \ --sitemap.domain=xlog.emadelsaid.com \ --activitypub.domain=xlog.emadelsaid.com \ - --activitypub.username=me \ + --activitypub.username=self \ --activitypub.summary="Xlog is a static site generator for digital gardening written in Go. It serves markdown files as HTML and allows editing files online. It focuses on enriching markdown files and surfacing implicit links between pages." rm *.md chmod -R 0777 . diff --git a/extensions/activitypub/activitypub.go b/extensions/activitypub/activitypub.go index 37836c90..85fc36ff 100644 --- a/extensions/activitypub/activitypub.go +++ b/extensions/activitypub/activitypub.go @@ -92,8 +92,8 @@ type profileResponse struct { Inbox string `json:"inbox,omitempty"` Outbox string `json:"outbox,omitempty"` Endpoints map[string]string `json:"endpoints,omitempty"` - Icon string `json:"icon,omitempty"` - Image string `json:"image,omitempty"` + Icon map[string]string `json:"icon,omitempty"` + Image map[string]string `json:"image,omitempty"` } func profile(w Response, r Request) Output { @@ -120,8 +120,16 @@ func profile(w Response, r Request) Output { Endpoints: map[string]string{ "sharedInbox": fmt.Sprintf("https://%s/+/activitypub/@%s/inbox", domain, username), }, - Icon: fmt.Sprintf("https://%s/public/logo.png", domain), - Image: fmt.Sprintf("https://%s/public/logo.png", domain), + Icon: map[string]string{ + "type": "Image", + "mediaType": "image/png", + "href": fmt.Sprintf("https://%s/public/logo.png", domain), + }, + Image: map[string]string{ + "type": "Image", + "mediaType": "image/png", + "href": fmt.Sprintf("https://%s/public/logo.png", domain), + }, }, )