When trying to convert the payload in realtime of the account channel to the "User" model it throws an error.
Same for the teams channel when trying to convert to the "Teams" model. Apparently realtime returns a list for preferences for the User and Team model instead of a map. Retrieving the models from the REST api work as expected but not from realtime.
This has already been mentioned in a comment here:
appwrite/sdk-for-flutter#33
I'm using Appwrite 1.5.2 selfhosted and appwrite 12.0.1 for flutter.
TL;DR
Issue with Appwrite returning a List instead of a Map for User and Account models in realtime. Problem also noticed with Teams model. REST API retrieval works fine, but not realtime. Mentioned in appwrite/sdk-for-flutter#33 comment. Using Appwrite 1.5.2 self-hosted and 12.0.1 for flutter.