diff --git a/src/isnd/Controllers/HomeController.cs b/src/isnd/Controllers/HomeController.cs index 2d0f766..6c3836b 100644 --- a/src/isnd/Controllers/HomeController.cs +++ b/src/isnd/Controllers/HomeController.cs @@ -59,9 +59,9 @@ namespace isnd.Controllers return View(ViewData); } - public IActionResult Error() + public IActionResult Error(string id) { - return View(); + return View("Error", id); } } } diff --git a/src/isnd/Startup.cs b/src/isnd/Startup.cs index 38c3efb..ac0078a 100644 --- a/src/isnd/Startup.cs +++ b/src/isnd/Startup.cs @@ -144,7 +144,7 @@ namespace isnd app.UseHsts(); dbContext.Database.Migrate(); } - app.UseStatusCodePages().UseStaticFiles().UseAuthentication(); + app.UseStatusCodePagesWithReExecute("/Home/Error/{0}").UseStaticFiles().UseAuthentication(); app.UseMvcWithDefaultRoute(); } } diff --git a/src/isnd/Views/Home/Error.cshtml b/src/isnd/Views/Home/Error.cshtml index 52fae93..01174c5 100644 --- a/src/isnd/Views/Home/Error.cshtml +++ b/src/isnd/Views/Home/Error.cshtml @@ -1,4 +1,8 @@ +@model string @{ ViewData["Title"] = "Error"; } +

@ViewData["Title"]

+ +

@Model

\ No newline at end of file