Use User:: API insteadd of direct database read

2022.09-rc
Dean Townsley 2019-06-22 18:56:33 -05:00
rodzic 042fcfeb50
commit 9dff3d2b6d
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -2928,7 +2928,7 @@ class DFRN
$baseurl = substr($baseurl, $domain_st + 3); $baseurl = substr($baseurl, $domain_st + 3);
$nurl = Strings::normaliseLink($baseurl); $nurl = Strings::normaliseLink($baseurl);
$r = DBA::selectFirst("user", ["uid"], ["nickname" => DBA::escape($contact_nick)], []); $r = User::getByNickname($contact_nick, ["uid"]);
$contact_uid = $r["uid"]; $contact_uid = $r["uid"];
/// @todo Why is there a query for "url" *and* "nurl"? Especially this normalising is strange. /// @todo Why is there a query for "url" *and* "nurl"? Especially this normalising is strange.