[mastodon-client] Return content_type for statuses

This commit is contained in:
Laura Hausmann 2023-10-16 23:21:01 +02:00
parent c64f6b6db6
commit 97176e00f9
No known key found for this signature in database
GPG Key ID: D044E84C5BE01605
2 changed files with 2 additions and 0 deletions

View File

@ -118,6 +118,7 @@ export class NoteConverter {
in_reply_to_account_id: note.replyUserId,
reblog: reblog.then(reblog => note.text === null ? reblog : null),
content: text.then(async text => text !== null ? MfmHelpers.toHtml(mfm.parse(text), JSON.parse(note.mentionedRemoteUsers), note.userHost).then(p => p ?? escapeMFM(text)) : ""),
content_type: 'text/x.misskeymarkdown',
text: text,
created_at: note.createdAt.toISOString(),
emojis: noteEmoji,

View File

@ -18,6 +18,7 @@ namespace MastodonEntity {
in_reply_to_account_id: string | null;
reblog: Status | null;
content: string | undefined;
content_type: string;
text: string | null | undefined;
created_at: string;
emojis: Emoji[];