Forum Discussion
alexkovalev
Dec 22, 2021Copper Contributor
Teams Notification Bot: TeamsInfo.getPagedMembers is sometimes not returning newly added members
Hi, I am a developer for a 3rd party Teams app. We include a built in notification bot that sends notifications to users of the app. To find these users, we implement https://docs.microsoft.com/en-u...
alexkovalev
Dec 30, 2021Copper Contributor
Hi, we were finally able to get to the bottom of this issue. The problem was in this line: members.push(...pagedMembers.members.filter(m => !!m.email));
The problem is that the email property doesnt exist on the users with issues, but it seems another field userPrincipalName is available with the user email for both the users that have the email field and dont.
Can you confirm if this is the correct solution, and if there are any unintended side effects with changing the code to read from email to userPrincipalName?
The problem is that the email property doesnt exist on the users with issues, but it seems another field userPrincipalName is available with the user email for both the users that have the email field and dont.
Can you confirm if this is the correct solution, and if there are any unintended side effects with changing the code to read from email to userPrincipalName?
HunaidHanfee-MSFT
Dec 31, 2021Iron Contributor
Thanks for the reply and the information shared. I need verify this internally, I will get back to you soon.