mirror of
https://github.com/meeb/tubesync.git
synced 2025-06-24 14:06:36 +00:00
maxsplit and quoting
This commit is contained in:
parent
279a01f9bc
commit
a02fd5bde9
@ -112,14 +112,14 @@ DOWNLOAD_VIDEO_DIR = 'video'
|
||||
DOWNLOAD_AUDIO_DIR = 'audio'
|
||||
SASS_PROCESSOR_ROOT = STATIC_ROOT
|
||||
|
||||
directory_mode = os.getenv("TUBESYNC_DIRECTORY_MODE", "default")
|
||||
directory_mode = os.getenv('TUBESYNC_DIRECTORY_MODE', 'default')
|
||||
if directory_mode == 'flat':
|
||||
DOWNLOAD_VIDEO_DIR = '.'
|
||||
DOWNLOAD_AUDIO_DIR = '.'
|
||||
elif directory_mode.startswith("custom:"):
|
||||
custom_value = directory_mode.split(":")[1]
|
||||
elif directory_mode.startswith('custom:'):
|
||||
custom_value = directory_mode.split(':', maxsplit=1)[1]
|
||||
if str(',') in custom_value:
|
||||
DOWNLOAD_AUDIO_DIR, DOWNLOAD_VIDEO_DIR = custom_value.split(',')
|
||||
DOWNLOAD_AUDIO_DIR, DOWNLOAD_VIDEO_DIR = custom_value.split(',', maxsplit=1)
|
||||
|
||||
|
||||
ROBOTS = '''
|
||||
|
Loading…
Reference in New Issue
Block a user