Provide known-good user.uri, remove User.profile_url/1

This commit is contained in:
Haelwenn (lanodan) Monnier 2020-03-30 02:01:09 +02:00
commit 185520d1b4
No known key found for this signature in database
GPG key ID: D5B7A8E43C997DEE
7 changed files with 19 additions and 13 deletions

View file

@ -68,7 +68,7 @@ defmodule Pleroma.Web.Metadata.Providers.OpenGraph do
property: "og:title",
content: Utils.user_name_string(user)
], []},
{:meta, [property: "og:url", content: User.profile_url(user)], []},
{:meta, [property: "og:url", content: user.uri || user.ap_id], []},
{:meta, [property: "og:description", content: truncated_bio], []},
{:meta, [property: "og:type", content: "website"], []},
{:meta, [property: "og:image", content: Utils.attachment_url(User.avatar_url(user))], []},