This commit is contained in:
@@ -174,7 +174,7 @@ namespace AyaNova
|
||||
options.AddPolicy("CorsPolicy",
|
||||
builder => builder.AllowAnyOrigin()
|
||||
.AllowAnyMethod()
|
||||
.AllowAnyHeader().SetPreflightMaxAge(TimeSpan.FromSeconds(600))
|
||||
.AllowAnyHeader().SetPreflightMaxAge(TimeSpan.FromSeconds(600))
|
||||
);
|
||||
});
|
||||
|
||||
@@ -547,6 +547,11 @@ namespace AyaNova
|
||||
_newLog.LogDebug("DB schema check");
|
||||
AySchema.CheckAndUpdateAsync(dbContext, _newLog).Wait();
|
||||
|
||||
// #if (DEBUG)
|
||||
// System.Diagnostics.Debugger.Log(1, "BOOT", "Startup.cs -> RE-PRIMING TRANSLATIONS");
|
||||
// AyaNova.Biz.PrimeData.RePrimeTranslations().Wait();
|
||||
// #endif
|
||||
|
||||
//Check database integrity
|
||||
_newLog.LogDebug("DB integrity check");
|
||||
DbUtil.CheckFingerPrintAsync(AySchema.EXPECTED_COLUMN_COUNT, AySchema.EXPECTED_INDEX_COUNT, _newLog).Wait();
|
||||
@@ -583,7 +588,7 @@ namespace AyaNova
|
||||
{
|
||||
//to support html5 pushstate routing in spa
|
||||
//this ensures that a refresh at the client will not 404 but rather force back to the index.html app page and then handled internally by the client
|
||||
await next();
|
||||
await next();
|
||||
if (!context.Response.HasStarted && !context.Request.Path.Value.StartsWith("/api") && context.Request.Path.Value != "/docs" && context.Response.StatusCode == 404 && !Path.HasExtension(context.Request.Path.Value))
|
||||
{
|
||||
context.Request.Path = "/index.html";
|
||||
|
||||
Reference in New Issue
Block a user