Show the preferredUsername in name is "".

This commit is contained in:
default 2022-09-30 18:28:46 +02:00
parent fa9c90c00e
commit 8e27f1d711

2
html.c
View file

@ -160,7 +160,7 @@ d_char *html_msg_icon(snac *snac, d_char *os, char *msg)
char *v;
/* get the name */
if ((v = xs_dict_get(actor, "name")) == NULL) {
if ((v = xs_dict_get(actor, "name")) == NULL || *v == '\0') {
if ((v = xs_dict_get(actor, "preferredUsername")) == NULL) {
v = "user";
}