@bartek updated identityClient.findUserIdentities to also return reservedUserIdentifiers - usernames of users not registered with identity, but registered with the keyserver. This means we can go back to stripping usernames from responses sent by the keyserver and request them from identity. This will now work for all users.
This diff addresses ENG-8771. It reverts D12674 with the following changes:
- In discardKeyserverUsernames we no longer check if id === bots.commbot.userID. This is because commbot is in reservedUserIdentifiers both on stagining and prod
- In discardKeyserverUsernames we check if usingCommServicesAccessToken. If not, we return the userInfos unchanged. This is because we cannot call the identity if there is no CSAT, so we need to keep the keyserver usernames