Condensed convoluted ternary
This commit is contained in:
parent
49e05d9f2b
commit
0c429fb0f1
1 changed files with 1 additions and 5 deletions
|
@ -178,10 +178,6 @@ export function createAccountFromServerJSON(serverJSON: ApiAccountJSON) {
|
||||||
),
|
),
|
||||||
note_emojified: emojify(accountJSON.note, emojiMap),
|
note_emojified: emojify(accountJSON.note, emojiMap),
|
||||||
note_plain: unescapeHTML(accountJSON.note),
|
note_plain: unescapeHTML(accountJSON.note),
|
||||||
url:
|
url: accountJSON[/^https?:\/\//.test(accountJSON.url) ? 'url' : 'uri'],
|
||||||
accountJSON.url.startsWith('http://') ||
|
|
||||||
accountJSON.url.startsWith('https://')
|
|
||||||
? accountJSON.url
|
|
||||||
: accountJSON.uri,
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue