Fixed the startup error

This commit is contained in:
tidusjar 2019-11-15 22:47:51 +00:00
commit 3bd9b18b33
2 changed files with 7 additions and 11 deletions

View file

@ -14,13 +14,9 @@ namespace Ombi.Store.Context.Sqlite
_created = true; _created = true;
Upgrade(); Upgrade();
Database.SetCommandTimeout(60); Database.SetCommandTimeout(60);
try
{
Database.Migrate(); Database.Migrate();
}
catch (SqliteException e) when (e.Message.Equals("duplicate column name: RequestId"))
{
}
} }

View file

@ -8,10 +8,10 @@ namespace Ombi.Store.Migrations.ExternalSqlite
protected override void Up(MigrationBuilder migrationBuilder) protected override void Up(MigrationBuilder migrationBuilder)
{ {
migrationBuilder.AddColumn<int>( //migrationBuilder.AddColumn<int>(
name: "RequestId", // name: "RequestId",
table: "PlexServerContent", // table: "PlexServerContent",
nullable: true); // nullable: true);
} }
protected override void Down(MigrationBuilder migrationBuilder) protected override void Down(MigrationBuilder migrationBuilder)