public async Task <ActionResponse> RegisterAsync(UserRegister model) { try { var replay = await _client.RegisterAsync(new RegisterRequest { Email = model.Email, Name = model.Name, Password = model.Password }); return(ToActionResponse(replay)); } catch { _logger.LogError("User registration has failed"); return(GetUnauthorizedAccessError()); } }