Skip to content

Commit

Permalink
Added protected ReturnErrorResult to ApiBaseController
Browse files Browse the repository at this point in the history
  • Loading branch information
NickKvizhinadze committed May 16, 2020
1 parent 767b75e commit e9bfcd3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions DotNetHelpers.MvcCore/ApiBaseController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,8 @@ protected IActionResult CustomResult(Result result)

return NoContent();
}
#endregion

#region Private Methods
private ActionResult ReturnErrorResult(Result result)
protected ActionResult ReturnErrorResult(Result result)
{
AddErrors(result.Errors);
switch (result.ErrorStatus)
Expand All @@ -43,7 +41,9 @@ private ActionResult ReturnErrorResult(Result result)
return CustomActionResult(HttpStatusCode.BadRequest);
}
}
#endregion

#region Private Methods
private ActionResult CustomActionResult(HttpStatusCode statusCode)
{
switch (statusCode)
Expand Down

0 comments on commit e9bfcd3

Please sign in to comment.