aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/utils.py
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2017-08-09 22:28:19 +0700
committerSergey M․ <dstftw@gmail.com>2017-08-09 22:28:19 +0700
commit5b232f46dcbdc805507c02edd4fd598f31d544d5 (patch)
treec7e864728fff306d5862c843bc2c7d2191302ed8 /youtube_dl/utils.py
parent4bf22f7a1014c55e3358b5a419945071b152eafc (diff)
[utils] Skip missing params in cli_bool_option (closes #13865)
Diffstat (limited to 'youtube_dl/utils.py')
-rw-r--r--youtube_dl/utils.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/youtube_dl/utils.py b/youtube_dl/utils.py
index fdf5e29e7..c9cbd5842 100644
--- a/youtube_dl/utils.py
+++ b/youtube_dl/utils.py
@@ -2733,6 +2733,8 @@ def cli_option(params, command_option, param):
def cli_bool_option(params, command_option, param, true_value='true', false_value='false', separator=None):
param = params.get(param)
+ if param is None:
+ return []
assert isinstance(param, bool)
if separator:
return [command_option + separator + (true_value if param else false_value)]