Hi all,
I have migrated an old aspx site to V4.0 of nopcommerce and would like to make sure that the depricated pages, rather than show the Page not found, go to the home page. What is the best way to do this?
Thanks,
Jon
public void Configure(IApplicationBuilder application)
{
application.Use(async (context, next) =>
{
await next();
if (context.Response.StatusCode == 404)
{
context.Request.Path = "/Home";
await next();
}
});
application.ConfigureRequestPipeline();
}