Tomic R.Original post
Rank 3: Container
Hi! I have the following code (dart/flutter):
Dart
final response = await _teams.get(teamId: teamId);
final teamMembers = await _teams.listMemberships(teamId: teamId);
print( teamMembers.memberships .map((e) => '${e.userId} ${e.roles}, ${e.userName}, ${e.userEmail}') .toList(),);The problem is, that I get this output:
[64ce2bb01c703cca4dd7 [owner], , , 66b39729ab248549d5d0 [owner], , ]
So as you can see, the userName and userEmail are not being returned. It's from client side, the user is logged in (and is in the team I am referring to) and in appwrite console, each team member to the team I am referring to has a name and obviously also has an email.
Summary
Problem: .listMemberships does not return user names and emails.
Solution: Ensure that the user authentication is correct and that the user is logged in on the client side. Check the permissions and data of team members in the appwrite console.