snac2

Fork of https://codeberg.org/grunfink/snac2
git clone https://git.inz.fi/snac2
Log | Files | Refs | README | LICENSE

commit ede2a38b2bb98b34ac44dcd6ed8710a25fe09990
parent 085c5a545aa9b7112deabe9dc51e1f99906b7cab
Author: default <nobody@localhost>
Date:   Tue, 25 Jul 2023 12:36:04 +0200

If an image has no description, try the post 'name' field.

Diffstat:
Mhtml.c | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/html.c b/html.c @@ -1194,6 +1194,8 @@ xs_str *html_entry(snac *snac, xs_str *os, const xs_dict *msg, int local, const char *name = xs_dict_get(v, "name"); if (xs_is_null(name)) + name = xs_dict_get(msg, "name"); + if (xs_is_null(name)) name = L("No description"); xs *es1 = encode_html(name);