Minor tweak to user_persist().

This commit is contained in:
default 2024-11-24 09:37:59 +01:00
parent 9fee970809
commit a2665c3cc9

3
data.c
View file

@ -350,6 +350,9 @@ int user_persist(snac *snac, int publish)
const char *of = xs_dict_get(old, fields[n]); const char *of = xs_dict_get(old, fields[n]);
const char *nf = xs_dict_get(snac->config, fields[n]); const char *nf = xs_dict_get(snac->config, fields[n]);
if (of == NULL && nf == NULL)
continue;
if (xs_type(of) != XSTYPE_STRING || xs_type(nf) != XSTYPE_STRING || strcmp(of, nf)) { if (xs_type(of) != XSTYPE_STRING || xs_type(nf) != XSTYPE_STRING || strcmp(of, nf)) {
nw = 1; nw = 1;
break; break;