Exemplo n.º 1
0
        public async Task <Result> ChangePassword(UserChangePasswordDTO user)
        {
            var usermodel = _mapper.Map <UserChangePasswordDTO, UserChangePassword>(user);

            try
            {
                var result = await _usersContext.ChangePassword(usermodel);

                return(result ? Result.Ok() : Result.Fail("PasswordChange Error"));
            }
            catch
            {
                return(Result.Fail("Error in change password"));
            }
        }
Exemplo n.º 2
0
 public async Task ChangePassword(UserChangePassword user)
 {
     await _usersContext.ChangePassword(user);
 }