Hi! I have the following code (dart/flutter):
TypeScript
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:
TypeScript
[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.
TL;DR
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.Recommended threads
- Can't deploy SERVER "Because of Internal...
Is there a problem with SGP Server right? Everytime I deploy a site it says Internal Server Error?
- Repository directory size should be less...
Whenever I create a function i get the error above. Is there a way to get around this? How do I fix this?
- Cant get realtime working
Hey I nned some help with realtime a gain. I was using client.subscribe(...), and i found out that its depricated then i believe realtime.subscribe(...) is the ...