From 9b547cb43ec6a3d28d4f35cef15ac90e465aa695 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Tue, 15 Dec 2020 19:36:45 +0200 Subject: Slightly improved RoleController readability --- src/DevHive.Web/Controllers/RoleController.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/DevHive.Web/Controllers/RoleController.cs') diff --git a/src/DevHive.Web/Controllers/RoleController.cs b/src/DevHive.Web/Controllers/RoleController.cs index e39d858..5e73357 100644 --- a/src/DevHive.Web/Controllers/RoleController.cs +++ b/src/DevHive.Web/Controllers/RoleController.cs @@ -24,7 +24,9 @@ namespace DevHive.Web.Controllers [HttpPost] public Task Create(CreateRoleWebModel createRoleWebModel) { - RoleServiceModel roleServiceModel = this._roleMapper.Map(createRoleWebModel); + RoleServiceModel roleServiceModel = + this._roleMapper.Map(createRoleWebModel); + return this._service.CreateRole(roleServiceModel); } @@ -37,7 +39,9 @@ namespace DevHive.Web.Controllers [HttpPut] public Task Update(UpdateRoleWebModel updateRoleWebModel) { - RoleServiceModel roleServiceModel = this._roleMapper.Map(updateRoleWebModel); + RoleServiceModel roleServiceModel = + this._roleMapper.Map(updateRoleWebModel); + return this._service.UpdateRole(roleServiceModel); } -- cgit v1.2.3