1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2024-12-16 11:37:58 +02:00

Fixed: Only vacuum the main db on startup

This commit is contained in:
Mark McDowall 2014-03-17 17:18:03 -07:00
parent e4de87c0ad
commit b60633882e

View File

@ -15,7 +15,6 @@ public interface IDbFactory
IDatabase Create(MigrationType migrationType = MigrationType.Main); IDatabase Create(MigrationType migrationType = MigrationType.Main);
} }
public class DbFactory : IDbFactory public class DbFactory : IDbFactory
{ {
private readonly IMigrationController _migrationController; private readonly IMigrationController _migrationController;
@ -79,8 +78,11 @@ public IDatabase Create(MigrationType migrationType = MigrationType.Main)
return dataMapper; return dataMapper;
}); });
db.Vacuum();
if (migrationType == MigrationType.Main)
{
db.Vacuum();
}
return db; return db;
} }