Delete the schedules db on startup, we don't want it trying to recover the jobs

pull/2922/head
tidusjar 6 years ago
parent cf9bb889ed
commit a499782ec0

@ -49,6 +49,7 @@ namespace Ombi
demoInstance.Demo = demo;
instance.StoragePath = storagePath ?? string.Empty;
// Check if we need to migrate the settings
DeleteSchedules();
CheckAndMigrate();
var ctx = new SettingsContext();
var config = ctx.ApplicationConfigurations.ToList();
@ -97,6 +98,20 @@ namespace Ombi
CreateWebHostBuilder(args).Build().Run();
}
private static void DeleteSchedules()
{
try
{
if (File.Exists("Schedules.db"))
{
File.Delete("Schedules.db");
}
}
catch (Exception)
{
}
}
/// <summary>
/// This is to remove the Settings from the Ombi.db to the "new"
/// OmbiSettings.db

Loading…
Cancel
Save