Share via


UserManager<TUser>.ChangeEmailAsync(TUser, String, String) Method

Definition

Updates a users emails if the specified email change token is valid for the user.

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Identity::IdentityResult ^> ^ ChangeEmailAsync(TUser user, System::String ^ newEmail, System::String ^ token);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult> ChangeEmailAsync (TUser user, string newEmail, string token);
abstract member ChangeEmailAsync : 'User * string * string -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
override this.ChangeEmailAsync : 'User * string * string -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.IdentityResult>
Public Overridable Function ChangeEmailAsync (user As TUser, newEmail As String, token As String) As Task(Of IdentityResult)

Parameters

user
TUser

The user whose email should be updated.

newEmail
String

The new email address.

token
String

The change email token to be verified.

Returns

The Task that represents the asynchronous operation, containing the IdentityResult of the operation.

Applies to