mirror of
https://github.com/chibicitiberiu/ytsm.git
synced 2024-02-24 05:43:31 +00:00
Merge branch 'refactor' of https://github.com/chibicitiberiu/ytsm into refactor
This commit is contained in:
@ -5,7 +5,12 @@ import json
|
||||
|
||||
|
||||
def fix_video_provider(apps, schema_editor):
|
||||
globalPrefs = apps.get_model('dynamic_preferences', 'GlobalPreferenceModel')
|
||||
try:
|
||||
globalPrefs = apps.get_model('dynamic_preferences', 'GlobalPreferenceModel')
|
||||
except LookupError as e:
|
||||
print("Warning: could not get dynamic_preferences model.")
|
||||
return
|
||||
|
||||
api_key_entries = globalPrefs.objects.filter(name='youtube_api_key')
|
||||
if len(api_key_entries) < 1:
|
||||
return
|
||||
|
Reference in New Issue
Block a user