Skip to content
This repository has been archived by the owner on Dec 14, 2018. It is now read-only.

Commit

Permalink
Removed custom object result accepting status code as out of box Obje…
Browse files Browse the repository at this point in the history
…ctResult provides this already.
  • Loading branch information
kichalla committed Feb 2, 2015
1 parent 514460b commit 49294b7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 26 deletions.
25 changes: 0 additions & 25 deletions test/WebSites/FormatterWebSite/ActionResults/CustomObjectResult.cs

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public override void OnActionExecuting(ActionExecutingContext context)
{
if (!context.ModelState.IsValid)
{
context.Result = new CustomObjectResult(context.ModelState, 400);
context.Result = new ObjectResult(context.ModelState) { StatusCode = 400 };
}
}
}
Expand Down

0 comments on commit 49294b7

Please sign in to comment.