public IActionResult DeclineDeleteRequest(DeleteRequestViewModel vm) { if (!ModelState.IsValid) { return(View(vm)); } var loggedModerator = _userService.FindByIdentityUserId(User.FindFirstValue(ClaimTypes.NameIdentifier)); try { _materialsService.DeclineDeleteRequest(vm.DeleteRequestId, loggedModerator, vm.DeclineReason); } catch (ArgumentException) { return(RedirectToAction("ResourceNotFound", "Error", new { error = "sugestia usunięcia o podanym Id nie istnieje." })); } return(RedirectToAction("DeleteSuggestions")); }