summaryrefslogtreecommitdiff
path: root/src/mailman/database/model.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/mailman/database/model.py')
-rw-r--r--src/mailman/database/model.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mailman/database/model.py b/src/mailman/database/model.py
index 6019b7488..c2ee90491 100644
--- a/src/mailman/database/model.py
+++ b/src/mailman/database/model.py
@@ -37,7 +37,7 @@ class ModelMeta:
try:
# Delete all the tables in reverse foreign key dependency
# order. http://tinyurl.com/on8dy6f
- for table in reversed(Model.metadata.sorted_tables): # noqa
+ for table in reversed(Model.metadata.sorted_tables):
connection.execute(table.delete())
except:
transaction.rollback()
@@ -46,4 +46,5 @@ class ModelMeta:
transaction.commit()
-public(Model=declarative_base(cls=ModelMeta))
+Model = declarative_base(cls=ModelMeta)
+public(Model=Model)