aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/screens/profile/InviteFriendsScreen.tsx8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/screens/profile/InviteFriendsScreen.tsx b/src/screens/profile/InviteFriendsScreen.tsx
index cc783b25..53e6b221 100644
--- a/src/screens/profile/InviteFriendsScreen.tsx
+++ b/src/screens/profile/InviteFriendsScreen.tsx
@@ -90,18 +90,18 @@ const InviteFriendsScreen: React.FC<InviteFriendsScreenProps> = ({route}) => {
if (query.length > 0) {
const searchResultsUsers = usersFromContacts.filter(
(item: ProfilePreviewType) =>
- item.last_name.toLowerCase().startsWith(query) ||
(item.first_name + ' ' + item.last_name)
.toLowerCase()
.startsWith(query) ||
- item.username.toLowerCase().startsWith(query),
+ item.username.toLowerCase().startsWith(query) ||
+ item.last_name.toLowerCase().startsWith(query),
);
const searchResultsNonUsers = nonUsersFromContacts.filter(
(item) =>
- item.lastName.toLowerCase().startsWith(query) ||
(item.firstName + ' ' + item.lastName)
.toLowerCase()
- .startsWith(query),
+ .startsWith(query) ||
+ item.lastName.toLowerCase().startsWith(query),
);
const sanitizedResult = {
usersFromContacts: searchResultsUsers,