Users: Consider nickname when searching for a user

Closes #465
This commit is contained in:
Maxim Leshchenko 2022-02-08 15:44:20 +02:00
parent 881665831e
commit 5f376b0517
No known key found for this signature in database
GPG key ID: BB9C44A8733FBEEE

View file

@ -39,7 +39,7 @@ class Users
function find(string $query): Util\EntityStream
{
$query = "%$query%";
$result = $this->users->where("CONCAT_WS(' ', first_name, last_name) LIKE ?", $query)->where("deleted", 0);
$result = $this->users->where("CONCAT_WS(' ', first_name, last_name, pseudo) LIKE ?", $query)->where("deleted", 0);
return new Util\EntityStream("User", $result);
}