mirror of
https://codeberg.org/grunfink/snac2.git
synced 2024-11-22 21:35:04 +00:00
_timeline_parent() does not need to be recursive (or does it?).
This commit is contained in:
parent
51dc99a86d
commit
b84267e4d3
1 changed files with 2 additions and 5 deletions
7
data.c
7
data.c
|
@ -403,8 +403,8 @@ void _timeline_parent(snac *snac, char *parent, char *child)
|
||||||
xs *children;
|
xs *children;
|
||||||
|
|
||||||
/* get the children list */
|
/* get the children list */
|
||||||
meta = xs_dict_get(msg, "_snac");
|
meta = xs_dup(xs_dict_get(msg, "_snac"));
|
||||||
children = xs_dict_get(meta, "children");
|
children = xs_dup(xs_dict_get(meta, "children"));
|
||||||
|
|
||||||
/* add */
|
/* add */
|
||||||
children = xs_list_append(children, child);
|
children = xs_list_append(children, child);
|
||||||
|
@ -438,9 +438,6 @@ void _timeline_parent(snac *snac, char *parent, char *child)
|
||||||
snac_debug(snac, 1,
|
snac_debug(snac, 1,
|
||||||
xs_fmt("_timeline_parent (local) updated %s %s", parent, lfn));
|
xs_fmt("_timeline_parent (local) updated %s %s", parent, lfn));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* retry with grampa */
|
|
||||||
_timeline_parent(snac, xs_dict_get(meta, "parent"), parent);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
snac_log(snac, xs_fmt("_timeline_parent error writing %s %s", parent, nfn));
|
snac_log(snac, xs_fmt("_timeline_parent error writing %s %s", parent, nfn));
|
||||||
|
|
Loading…
Reference in a new issue