snac2

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

commit 13ffca1d029f47cc3f9fd92824d75aa1010a64db
parent dfd246a0e9df31f315f1fd650c9b916195b2c9e4
Author: grunfink <grunfink@comam.es>
Date:   Sat,  7 Jun 2025 10:05:23 +0200

Another search by URL tweak (for Pixelfed).

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

diff --git a/html.c b/html.c @@ -3795,6 +3795,14 @@ int html_get_handler(const xs_dict *req, const char *q_path, timeline_add(&snac, q, object); } } + else { + /* retry webfinger, this time with the 'official' id */ + const char *id = xs_dict_get(object, "id"); + + if (xs_is_string(id) && valid_status(webfinger_request(id, &actor_obj, &url_acct)) && + xs_is_string(url_acct)) + q = url_acct; + } } }