mirror of
https://github.com/spaam/svtplay-dl.git
synced 2024-11-27 21:54:17 +01:00
util: Fix some exceptions
This commit is contained in:
parent
0de19d2c11
commit
370a1b507b
@ -195,9 +195,17 @@ def subtitle_wsrt(options, data):
|
||||
def select_quality(options, streams):
|
||||
available = sorted(streams.keys(), key=int)
|
||||
|
||||
try:
|
||||
optq = int(options.quality)
|
||||
except ValueError:
|
||||
log.error("Requested quality need to be a number")
|
||||
sys.exit(4)
|
||||
if optq:
|
||||
try:
|
||||
optf = int(options.flexibleq)
|
||||
except ValueError:
|
||||
log.error("Flexible-quality need to be a number")
|
||||
sys.exit(4)
|
||||
if not optf:
|
||||
wanted = [optq]
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user