mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-12 10:04:26 +02:00
API: Only search for direct hit without offset
This commit is contained in:
parent
215c332a94
commit
6965614f00
2 changed files with 5 additions and 4 deletions
|
@ -108,7 +108,7 @@ class Search extends BaseApi
|
|||
private static function searchAccounts(int $uid, string $q, bool $resolve, int $limit, int $offset, bool $following)
|
||||
{
|
||||
if (
|
||||
(strrpos($q, '@') > 0 || Network::isValidHttpUrl($q))
|
||||
($offset == 0) && (strrpos($q, '@') > 0 || Network::isValidHttpUrl($q))
|
||||
&& $id = Contact::getIdForURL($q, 0, $resolve ? null : false)
|
||||
) {
|
||||
return DI::mstdnAccount()->createFromContactId($id, $uid);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue