Skip to content

Commit

Permalink
database.upgrade - fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
MatteoCampinoti94 committed Aug 5, 2024
1 parent 75a1865 commit b99d8f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions acacore/database/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ def get_db_version(db: FileDB) -> Version:
def set_db_version(db: FileDB, version: Version) -> Version:
metadata = db.metadata.select()
metadata.version = str(version)
db.metadata.upgrade(metadata)
db.metadata.update(metadata)
db.commit()
return version

Expand All @@ -40,7 +40,7 @@ def upgrade_1to2(db: FileDB) -> Version:
db.execute("update Files set lock = false where lock is null")
db.execute("update Files set action = 'template' where action = 'replace'")
for file in db.files.select():
db.files.upgrade(file)
db.files.update(file)
return set_db_version(db, Version("2.0.0"))


Expand Down

0 comments on commit b99d8f8

Please sign in to comment.