diff options
| author | transtrike <transtrike@gmail.com> | 2020-12-15 20:03:21 +0200 |
|---|---|---|
| committer | transtrike <transtrike@gmail.com> | 2020-12-15 20:03:21 +0200 |
| commit | fb8d06ecb1d38e1430902342f75bd135db44dafa (patch) | |
| tree | 4e9715d0bf4624a06ee0d0c540ea4ae573acc97f /src | |
| parent | 85b41def10318ff04e72991008ba7d0e623a7674 (diff) | |
| download | DevHive-fb8d06ecb1d38e1430902342f75bd135db44dafa.tar DevHive-fb8d06ecb1d38e1430902342f75bd135db44dafa.tar.gz DevHive-fb8d06ecb1d38e1430902342f75bd135db44dafa.zip | |
Fixed UpdateUser in UserService
Diffstat (limited to 'src')
| -rw-r--r-- | src/DevHive.Data/Repositories/RoleRepository.cs | 2 | ||||
| -rw-r--r-- | src/DevHive.Web/Controllers/UserController.cs | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/DevHive.Data/Repositories/RoleRepository.cs b/src/DevHive.Data/Repositories/RoleRepository.cs index 5ddadab..1c40b04 100644 --- a/src/DevHive.Data/Repositories/RoleRepository.cs +++ b/src/DevHive.Data/Repositories/RoleRepository.cs @@ -13,7 +13,7 @@ namespace DevHive.Data.Repositories } //Find entity by id - public async Task<TEntity> GetByIdAsync(Guid id) + public async Task<Role> GetByIdAsync(Guid id) { throw new NotImplementedException(); } diff --git a/src/DevHive.Web/Controllers/UserController.cs b/src/DevHive.Web/Controllers/UserController.cs index 480fbe4..900af42 100644 --- a/src/DevHive.Web/Controllers/UserController.cs +++ b/src/DevHive.Web/Controllers/UserController.cs @@ -55,8 +55,9 @@ namespace DevHive.Web.Controllers public async Task<IActionResult> Update(Guid id, [FromBody] UpdateUserWebModel updateModel) { UpdateUserServiceModel updateUserServiceModel = this._userMapper.Map<UpdateUserServiceModel>(updateModel); + updateUserServiceModel.Id = id; - return await this._service.UpdateUser(id, updateUserServiceModel); + return await this._service.UpdateUser(updateUserServiceModel); } //Delete |
