From 7a384588d8cf273ec078d3370eebc4087eb92d75 Mon Sep 17 00:00:00 2001 From: emkael Date: Fri, 19 Feb 2016 13:30:20 +0100 Subject: * calendar import script (from reddit markdown) --- init_db.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'init_db.py') diff --git a/init_db.py b/init_db.py index da3e641..7d48e80 100644 --- a/init_db.py +++ b/init_db.py @@ -1,16 +1,16 @@ import sys from rcal.db import Session -from rcal.model import Base +from rcal.model import BASE def main(): session = Session.create() if len(sys.argv) > 1 and sys.argv[1] == 'force': - Base.metadata.drop_all(session.get_bind()) + BASE.metadata.drop_all(session.get_bind()) - Base.metadata.create_all(session.get_bind()) + BASE.metadata.create_all(session.get_bind()) if __name__ == '__main__': main() -- cgit v1.2.3