Fix DatabaseOutOfDate exception using wrong variable names.

This commit is contained in:
voussoir 2020-07-01 15:59:49 -07:00
parent 215a46591e
commit 5d000f87c3
2 changed files with 6 additions and 2 deletions

View file

@ -64,5 +64,9 @@ class BadTable(BadSQL):
# GENERAL ERRORS # GENERAL ERRORS
OUTOFDATE = '''
Database is out of date. {existing} should be {new}.
Please run utilities\\database_upgrader\\database_upgrader.py "{filepath.absolute_path}"
'''.strip()
class DatabaseOutOfDate(YCDLException): class DatabaseOutOfDate(YCDLException):
error_message = 'Database is out-of-date. {current} should be {new}.' error_message = OUTOFDATE

View file

@ -413,7 +413,7 @@ class YCDLDB(
raise exceptions.DatabaseOutOfDate( raise exceptions.DatabaseOutOfDate(
existing=existing, existing=existing,
new=constants.DATABASE_VERSION, new=constants.DATABASE_VERSION,
filepath=self.database_filepath, filepath=self.data_directory,
) )
def _first_time_setup(self): def _first_time_setup(self):