Hey @ahmaddanial, I’m actually looking at this right now. It seems the mobile app simply doesn’t search the nickname attribute. Here’s a reference to where I’m looking at the source code. I’m fairly confident the function above is returning all properties of the
UserProfile which you can see here and I also did a quick test adding some debugging code into
autocomplete.js where I can see full user profiles being returned (with the nickname attribute).
Here’s a basic example:
There is a user with the following profile attributes:
- First name: John
- Last name: Doe
- Email: email@example.com
- Username: johndoe
- Nickname: Dragon
When you starting typing @ in the channel post bar, it begins searching for users in your team or server. In the web app, it appears to be searching all five of the attributes mentioned above so if I type in @dragon, it will find the user.
However, on the mobile app, it only appears to be searching the first four attributes so if I type in @dragon, it will not find the user.
If I add the following to the source code:
It appears to be working but I’m also testing this on a Mattermost instance with 16k+ users, so there’s some users I can’t seem to find by nickname but I’m fairly certain it’s based on however the database is refreshed.