Skip to content

Commit 8ab1d77

Browse files
committed
Introduced ASP.NET Core status code error handling
With the introduction of the new `ErrorController` (e7fe64f), I've introduced the `UseStatusCodePagesWithReExecute()` configuration to the `Host` project.
1 parent bf46877 commit 8ab1d77

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

OnTopic.AspNetCore.Mvc.Host/Program.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@
5353
}
5454
else {
5555
app.UseExceptionHandler("/Home/Error");
56+
app.UseStatusCodePagesWithReExecute("/Error/{0}");
5657
// The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts.
5758
app.UseHsts();
5859
}

0 commit comments

Comments
 (0)