Use url if available (#6214)

* Fix #6213

* other link

* fix
This commit is contained in:
MeiMei 2020-04-02 21:59:14 +09:00 committed by GitHub
parent 331305e6c7
commit 356225af14
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 33 additions and 8 deletions

View file

@ -104,6 +104,7 @@ type Option = {
apHashtags?: string[] | null;
apEmojis?: string[] | null;
uri?: string | null;
url?: string | null;
app?: App | null;
};
@ -407,6 +408,7 @@ async function insertNote(user: User, data: Option, tags: string[], emojis: stri
});
if (data.uri != null) insert.uri = data.uri;
if (data.url != null) insert.url = data.url;
// Append mentions data
if (mentionedUsers.length > 0) {