also filter by username when adding people

This commit is contained in:
Sinclair Chen 2022-07-05 14:34:16 -07:00
parent 5eca9def9d
commit 270a5fc139

View File

@ -35,7 +35,8 @@ export function FilterSelectUsers(props: {
return ( return (
!selectedUsers.map((user) => user.name).includes(user.name) && !selectedUsers.map((user) => user.name).includes(user.name) &&
!ignoreUserIds.includes(user.id) && !ignoreUserIds.includes(user.id) &&
user.name.toLowerCase().includes(query.toLowerCase()) (user.name.toLowerCase().includes(query.toLowerCase()) ||
user.username.toLowerCase().includes(query.toLowerCase()))
) )
}) })
) )