fix(Search): display bot icon only for bots

Due to the way Android handles lists, the icon could be wrongly shown on
non-bot accounts.

Fixes https://github.com/LucasGGamerM/moshidon/issues/418.
This commit is contained in:
FineFindus
2024-05-27 13:41:25 +02:00
parent 18ac0423c0
commit 6cb8961639

View File

@@ -148,9 +148,7 @@ public class AccountViewHolder extends BindableViewHolder<AccountViewModel> impl
pronouns.setVisibility(pronounsString.isPresent() ? View.VISIBLE : View.GONE);
pronounsString.ifPresent(p -> HtmlParser.setTextWithCustomEmoji(pronouns, p, item.account.emojis));
if(item.account.bot) {
botIcon.setVisibility(View.VISIBLE);
}
botIcon.setVisibility(item.account.bot ? View.VISIBLE : View.GONE);
/* unused in megalodon
boolean hasVerifiedLink=item.verifiedLink!=null;