From e87887c3287a22b0d4a261de9be21d13bc02f174 Mon Sep 17 00:00:00 2001 From: Mario Date: Sun, 27 Nov 2022 09:40:23 +0000 Subject: re-install: make sure to fetch the latest hubloc in api_auth otherwise authentication might fail --- include/api_auth.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/api_auth.php b/include/api_auth.php index 0395dae7a..be886fbb2 100644 --- a/include/api_auth.php +++ b/include/api_auth.php @@ -102,13 +102,13 @@ function api_login(&$a) { if ($sigblock) { $keyId = str_replace('acct:', '', $sigblock['keyId']); if ($keyId) { - $r = q("select * from hubloc where hubloc_addr = '%s' or hubloc_id_url = '%s'", + $r = q("select * from hubloc where hubloc_addr = '%s' or hubloc_id_url = '%s' order by hubloc_id desc", dbesc($keyId), dbesc($keyId) ); if (!$r) { HTTPSig::get_zotfinger_key($keyId); - $r = q("select * from hubloc where hubloc_addr = '%s' or hubloc_id_url = '%s'", + $r = q("select * from hubloc where hubloc_addr = '%s' or hubloc_id_url = '%s' order by hubloc_id desc", dbesc($keyId), dbesc($keyId) ); -- cgit v1.2.3