From 7f1350268a9f5f49977241987a8eb8113a845faa Mon Sep 17 00:00:00 2001 From: Isaac Levin <8878502+isaac2004@users.noreply.github.com> Date: Fri, 12 Jul 2019 19:23:43 -0400 Subject: [PATCH 1/4] Update Startup.cs --- .../content/BlazorServerWeb-CSharp/Startup.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Startup.cs b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Startup.cs index f6d8f25248..f5a91824f6 100644 --- a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Startup.cs +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Startup.cs @@ -144,7 +144,7 @@ namespace BlazorServerWeb_CSharp } else { - app.UseExceptionHandler("/Home/Error"); + app.UseExceptionHandler("/Error"); #if (RequiresHttps) // The default HSTS value is 30 days. You may want to change this for production scenarios, see https://aka.ms/aspnetcore-hsts. app.UseHsts(); From 7ba5f7e8b9c09669b9dcbd41c409e22271b5bc72 Mon Sep 17 00:00:00 2001 From: Isaac Levin <8878502+isaac2004@users.noreply.github.com> Date: Fri, 12 Jul 2019 19:26:14 -0400 Subject: [PATCH 2/4] Add files via upload --- .../BlazorServerWeb-CSharp/Pages/Error.razor | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Pages/Error.razor diff --git a/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Pages/Error.razor b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Pages/Error.razor new file mode 100644 index 0000000000..cd87ea9518 --- /dev/null +++ b/src/ProjectTemplates/Web.ProjectTemplates/content/BlazorServerWeb-CSharp/Pages/Error.razor @@ -0,0 +1,16 @@ +@page "/error" + + +
+ Swapping to Development environment will display more detailed information about the error that occurred. +
++ The Development environment shouldn't be enabled for deployed applications. + It can result in displaying sensitive information from exceptions to end users. + For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development + and restarting the app. +
\ No newline at end of file From 7b4c073fc64cc1d845e5bf4380b9765fb1b4fa1c Mon Sep 17 00:00:00 2001 From: Isaac Levin