Update Startup.cs

Update to template to remove RazorPages extension if not an auth template
This commit is contained in:
Isaac Levin 2019-06-25 12:00:28 -04:00 committed by GitHub
parent cefeb6ba00
commit 343d6e4b9a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

View File

@ -120,7 +120,10 @@ namespace Company.WebApplication1
#else
services.AddControllersWithViews();
#endif
#if (OrganizationalAuth || IndividualAuth)
services.AddRazorPages();
#endif
}
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
@ -160,7 +163,10 @@ namespace Company.WebApplication1
endpoints.MapControllerRoute(
name: "default",
pattern: "{controller=Home}/{action=Index}/{id?}");
#if (OrganizationalAuth || IndividualAuth)
endpoints.MapRazorPages();
#endif
});
}
}