updateUserClaims method
Invites a new user into the workspace and returns Map<String,dynamic> if successful Throws UsersServiceException if failed
Implementation
Future<Map<String, dynamic>> updateUserClaims(
String userId, Map<String, dynamic> claims) async {
try {
final callable = _functions.httpsCallable('callables-updateUserClaims');
final result = await callable.call({'uid': userId, 'claims': claims});
final updatedClaims = result.data as Map<String, dynamic>;
return updatedClaims;
} on FirebaseFunctionsException catch (e) {
// Handle FirebaseFunctionsException
throw UserDataServiceException.fromRdevException(e.toRdevException());
} on Exception catch (e) {
// Handle other exceptions
throw UserDataServiceException(message: e.toString());
}
}