diff options
Diffstat (limited to 'init_db.py')
-rw-r--r-- | init_db.py | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -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() |