From ed25373bc72ffe06eaeba3dbd31a3b0dd2d8a427 Mon Sep 17 00:00:00 2001 From: Laura Hausmann Date: Sat, 21 Oct 2023 23:42:50 +0200 Subject: [PATCH] [mastodon-client] Return uri as url if status has no known url and is not local --- packages/backend/src/server/api/mastodon/converters/note.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/backend/src/server/api/mastodon/converters/note.ts b/packages/backend/src/server/api/mastodon/converters/note.ts index 1e1dc3c3f..813192d66 100644 --- a/packages/backend/src/server/api/mastodon/converters/note.ts +++ b/packages/backend/src/server/api/mastodon/converters/note.ts @@ -115,7 +115,7 @@ export class NoteConverter { return await awaitAll({ id: note.id, uri: note.uri ?? `https://${config.host}/notes/${note.id}`, - url: note.url ?? `https://${config.host}/notes/${note.id}`, + url: note.url ?? note.uri ?? `https://${config.host}/notes/${note.id}`, account: Promise.resolve(noteUser).then(p => UserConverter.encode(p, ctx)), in_reply_to_id: note.replyId, in_reply_to_account_id: note.replyUserId,