コード例 #1
0
        public async Task <IActionResult> ChangePasswordAsync([FromBody] ChangePasswordModel model)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest());
            }

            await _identityServiceProvider.ChangePasswordAsync(_httpContextAccessor.HttpContext.User.Identity.Name, model);

            return(NoContent());
        }