1
0
mirror of https://github.com/spaam/svtplay-dl.git synced 2024-11-27 21:54:17 +01:00

tv4play: dont use directory twice in output filename

it happens when the output is an directory
This commit is contained in:
Johan Andersson 2015-10-05 20:27:45 +02:00
parent e6baf3e4da
commit d4afbd778b

View File

@ -71,8 +71,9 @@ class Tv4play(Service, OpenGraphThumbMixin):
if options.output_auto: if options.output_auto:
directory = os.path.dirname(options.output) directory = os.path.dirname(options.output)
basename = os.path.basename(options.output)
options.service = "tv4play" options.service = "tv4play"
title = "%s-%s-%s" % (options.output, vid, options.service) title = "%s-%s-%s" % (basename, vid, options.service)
title = filenamify(title) title = filenamify(title)
if len(directory): if len(directory):
options.output = os.path.join(directory, title) options.output = os.path.join(directory, title)