From dfd246a0e9df31f315f1fd650c9b916195b2c9e4 Mon Sep 17 00:00:00 2001 From: grunfink Date: Sat, 7 Jun 2025 08:19:40 +0200 Subject: Always store resolved account handles as metadata, even if they weren't verified. --- utils.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/utils.c b/utils.c index d8c55dc..7adbce2 100644 --- a/utils.c +++ b/utils.c @@ -497,6 +497,14 @@ void verify_links(snac *user) if (valid_status(webfinger_request(v, &wfinger, NULL)) && xs_is_string(wfinger)) { ov = v; v = wfinger; + + /* store the alias */ + if (user->links == NULL) + user->links = xs_dict_new(); + + user->links = xs_dict_set(user->links, ov, v); + + changed++; } } @@ -575,10 +583,6 @@ void verify_links(snac *user) user->links = xs_dict_set(user->links, v, verified_time); - /* also add the original value if it was 'resolved' */ - if (xs_is_string(ov)) - user->links = xs_dict_set(user->links, ov, v); - vfied = 1; } else -- cgit v1.2.3