From cfbbdcc5ad08f2c6a0614cae2256880d6cbff8f6 Mon Sep 17 00:00:00 2001 From: Christopher Allan Webber Date: Mon, 2 Jan 2012 16:14:55 -0600 Subject: [PATCH] Another db->db.engine because I'm bad at things ;) Thanks again Elrond. --- mediagoblin/db/sql/util.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/mediagoblin/db/sql/util.py b/mediagoblin/db/sql/util.py index 0911884e..65976538 100644 --- a/mediagoblin/db/sql/util.py +++ b/mediagoblin/db/sql/util.py @@ -50,10 +50,10 @@ class MigrationManager(object): self.printer = printer # For convenience - from mediagoblin.db.sql.models import MigrationData + from mediagoblin.db.sql.models import MigrationRecord - self.migration_model = MigrationData - self.migration_table = MigrationData.__table__ + self.migration_model = MigrationRecord + self.migration_table = MigrationRecord.__table__ @property def sorted_migrations(self): @@ -251,8 +251,8 @@ def assure_migrations_table_setup(db): """ Make sure the migrations table is set up in the database. """ - from mediagoblin.db.sql.models import MigrationData + from mediagoblin.db.sql.models import MigrationRecord - if not MigrationData.__table__.exists(db): - MigrationData.metadata.create_all( - db, tables=[MigrationData.__table__]) + if not MigrationRecord.__table__.exists(db.engine): + MigrationRecord.metadata.create_all( + db, tables=[MigrationRecord.__table__]) -- 2.25.1