updateUser static method
Future<User?>
updateUser(
- User user, {
- dynamic onSuccess(
- User retUser
- dynamic onError(
- CometChatException excep
Updating a user similar to creating a user should ideally be achieved at your backend using the Restful APIs
user
a user object which user needs to be updated.
method could throw PlatformException
with error codes specifying the cause
Implementation
static Future<User?> updateUser(User user,
{Function(User retUser)? onSuccess,
Function(CometChatException excep)? onError}) async {
if (!checkAuthSettings(onError)) return null;
User? user0;
user0 = await CometChat.updateUser(user, authenticationSettings!.authKey!,
onSuccess: onSuccess, onError: onError);
return user0;
}