fix account name not displayed when not set

This commit is contained in:
Nicolas Constant 2019-08-10 14:26:54 -04:00
parent 77ac1764cd
commit fc6724d57e
No known key found for this signature in database
GPG Key ID: 1E9F677FB01A5688
1 changed files with 2 additions and 1 deletions

View File

@ -13,7 +13,8 @@ export class AccountEmojiPipe implements PipeTransform {
let textToTransform = text;
if(!text){
textToTransform = value.display_name;
if(value.display_name) textToTransform = value.display_name;
else textToTransform = value.acct.split('@')[0];
}
return this.emojiConverter.applyEmojis(value.emojis, textToTransform, EmojiTypeEnum.small)