public async Task ChangePasswordAsync(string currentPassword, string newPassword)
        {
            if (!CurrentUser.Id.HasValue)
            {
                throw new AbpException("Current user Id is null!");
            }

            var currentUser = await _userManager.GetByIdAsync(CurrentUser.Id.Value);

            (await _userManager.ChangePasswordAsync(currentUser, currentPassword, newPassword)).CheckErrors();
        }
Exemplo n.º 2
0
        public virtual async Task ChangePasswordAsync(ChangePasswordInput input)
        {
            var currentUser = await _userManager.GetByIdAsync(CurrentUser.GetId());

            (await _userManager.ChangePasswordAsync(currentUser, input.CurrentPassword, input.NewPassword)).CheckErrors();
        }
Exemplo n.º 3
0
        public async Task ChangePasswordAsync(string currentPassword, string newPassword)
        {
            var currentUser = await _userManager.GetByIdAsync(CurrentUser.GetId());

            (await _userManager.ChangePasswordAsync(currentUser, currentPassword, newPassword)).CheckErrors();
        }