I am currently trying to use an appwrite function to update and overwrite the data stored in a database collection for users with but the function doesn't seem to be working or called. The data is stored as a string list. Is there something wrong with how i'm calling it?
// Updating user topics
Future<bool> updateUserTopics(String userId, List<String> topics) async {
try {
await databases.updateDocument(
databaseId: '6581a7a98574997f7e84',
collectionId: '6581a97c17588b1fb066',
documentId: userId,
data: {
'Topics': topics
},
);
print("Topics updated successfully.");
return true;
} catch (e) {
print("Error updating topics: $e");
return false;
}
}
Recommended threads
- Invalid document structure: missing requ...
I just pick up my code that's working a week ago, and now I got this error: ``` code: 400, type: 'document_invalid_structure', response: { message: 'Inv...
- Apple OAuth Scopes
Hi Hi, I've configured sign in with apple and this is the response i'm getting from apple once i've signed in. I cant find anywhere I set scopes. I remember se...
- Sign In With Apple OAuth Help
Hi All! I've got a flutter & appwrite app which Im trying to use sign in with apple for. I already have sign in with google working and the function is the sam...