Search: Filter out deleted accounts

This commit is contained in:
Ilya Prokopenko 2022-01-27 14:46:28 +03:00
parent 22157c7fa3
commit 3796135c2f
No known key found for this signature in database
GPG key ID: 7736BBBB05F14A56

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);
$result = $this->users->where("CONCAT_WS(' ', first_name, last_name) LIKE ?", $query)->where("deleted", 0);
return new Util\EntityStream("User", $result);
}