updateProfile static method
update current user's profile.
Implementation
static Future<AuthResult> updateProfile(Map map) async {
var body = jsonEncode(map);
final Result result = await post('/api/v2/users/profile/update', body);
AuthResult authResult = AuthResult(result);
if (result.code == 200) {
authResult.user = await createUser(result);
}
return authResult;
}