From d29d79892a2e5e4867e72bb234af917b039b3c43 Mon Sep 17 00:00:00 2001 From: Andre Klapper Date: Wed, 25 Jun 2025 14:53:16 +0200 Subject: [PATCH] User search: Correct "Name Contains" (nameLike) query constraint description Summary: Passing a value for the `nameLike` parameter to `PhabricatorPeopleQuery` does not only search for that substring within usernames but also within realnames. Closes T16132 Test Plan: 1. Go to http://phorge.localhost/conduit/method/user.search/ and look at the Description for the `nameLike` constraint. 2. Set up a user with a username different from the realname. 3. Go to http://phorge.localhost/people/query/advanced/ and enter a substring of the realname into the `Name Contains` field, still get the user from step 2 listed in the query results. Reviewers: O1 Blessed Committers, valerio.bozzolan, mainframe98 Reviewed By: O1 Blessed Committers, valerio.bozzolan, mainframe98 Subscribers: mainframe98, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno Maniphest Tasks: T16132 Differential Revision: https://we.phorge.it/D26116 --- .../people/query/PhabricatorPeopleSearchEngine.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/applications/people/query/PhabricatorPeopleSearchEngine.php b/src/applications/people/query/PhabricatorPeopleSearchEngine.php index 1e0c0052c1..22b74674ad 100644 --- a/src/applications/people/query/PhabricatorPeopleSearchEngine.php +++ b/src/applications/people/query/PhabricatorPeopleSearchEngine.php @@ -28,7 +28,8 @@ final class PhabricatorPeopleSearchEngine ->setLabel(pht('Name Contains')) ->setKey('nameLike') ->setDescription( - pht('Find users whose usernames contain a substring.')), + pht( + 'Find users whose usernames or real names contain a substring.')), id(new PhabricatorSearchThreeStateField()) ->setLabel(pht('Administrators')) ->setKey('isAdmin') -- 2.51.2