Created
June 21, 2018 01:05
-
-
Save dcomartin/47086ebbf83682c691e2cb00b51647e1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public override void Configure(IApplicationBuilder app) | |
{ | |
app.UseProblemDetails(x => | |
{ | |
// This will map NotImplementedException to the 501 Not Implemented status code. | |
x.Map<NotImplementedException>(ex => new ExceptionProblemDetails(ex, StatusCodes.Status501NotImplemented)); | |
}); | |
app.UseMvc(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment