mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-11-22 13:25:04 +00:00
Fixed hide() to store the object id, not its md5.
This commit is contained in:
parent
4494fc3daf
commit
2176a91c64
1 changed files with 9 additions and 2 deletions
9
data.c
9
data.c
|
@ -1097,10 +1097,17 @@ void hide(snac *snac, const char *id)
|
|||
char *p, *v;
|
||||
|
||||
p = chld;
|
||||
while (xs_list_iter(&p, &v))
|
||||
while (xs_list_iter(&p, &v)) {
|
||||
xs *co = NULL;
|
||||
|
||||
/* resolve to get the id */
|
||||
if (valid_status(object_get_by_md5(v, &co, NULL))) {
|
||||
if ((v = xs_dict_get(co, "id")) != NULL)
|
||||
hide(snac, v);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int is_hidden(snac *snac, const char *id)
|
||||
|
|
Loading…
Reference in a new issue