YannickRe / spfx-msgraph-peoplesearch

Show and search users from your organization with an SPFx web part, through Microsoft Graph.
40 stars 33 forks source link

Profile Pictures not showing #10

Closed kendalldTalon closed 3 years ago

kendalldTalon commented 3 years ago

Profile pictures stop appearing after you enter a $select statement. Remove the $select statement and profile pictures reappear as you can see in the screenshots below. No Select Statement - Profile Photo Select Statement - No Profile Photo

YannickRe commented 3 years ago

@kendalldTalon You did not provide the values for your $select statement, so it is just an assumption. My guess is that you aren't selecting id in your $select statement. The code depends on this value for a user to fetch the user profile picture.

Could you confirm? Maybe add it in your $select statement and test? If this is the case, I'll make a note to improve the code and add this in even when it isn't explicitly selected.

kendalldTalon commented 3 years ago

Adding id to the select fixed the issue. Thanks.