diff --git a/bazarr/database.py b/bazarr/database.py index dd48e0e88..94846abd2 100644 --- a/bazarr/database.py +++ b/bazarr/database.py @@ -49,7 +49,7 @@ class TableShows(BaseModel): alternate_titles = TextField(column_name='alternateTitles', null=True) audio_language = TextField(null=True) fanart = TextField(null=True) - forced = TextField(null=True) + forced = TextField(null=True, constraints=[SQL('DEFAULT "False"')]) hearing_impaired = TextField(null=True) languages = TextField(null=True) overview = TextField(null=True) @@ -61,6 +61,10 @@ class TableShows(BaseModel): tvdb_id = IntegerField(column_name='tvdbId', null=True, unique=True, primary_key=True) year = TextField(null=True) + migrate( + migrator.add_column('table_shows', 'forced', forced), + ) + class Meta: table_name = 'table_shows' @@ -98,7 +102,7 @@ class TableMovies(BaseModel): audio_language = TextField(null=True) failed_attempts = TextField(column_name='failedAttempts', null=True) fanart = TextField(null=True) - forced = TextField(null=True) + forced = TextField(null=True, constraints=[SQL('DEFAULT "False"')]) format = TextField(null=True) hearing_impaired = TextField(null=True) imdb_id = TextField(column_name='imdbId', null=True) @@ -120,6 +124,7 @@ class TableMovies(BaseModel): movie_file_id = IntegerField(null=True) migrate( + migrator.add_column('table_movies', 'forced', forced), migrator.add_column('table_movies', 'movie_file_id', movie_file_id), )