diff options
author | Jaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com> | 2015-04-17 22:38:14 +0200 |
---|---|---|
committer | Jaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com> | 2015-04-17 22:38:14 +0200 |
commit | ecc6bd1341cd03fd335058371c3efa63dfd31152 (patch) | |
tree | 881b88fe0227805b4bc4d0ba61bba72b51bd7c49 | |
parent | ce81b1411d182fbfe7bd6da7b875d50f37ae38d6 (diff) | |
download | youtube-dl-ecc6bd1341cd03fd335058371c3efa63dfd31152.tar.xz |
YoutubeDL.post_process: simplify keep_video handling
Since keep_video started as None we always set it to keep_video_wish unless it was None, so in the end keep_video == keep_video_wish. This should have been changed in f3ff1a3696c4080468e2cc5810c34273b148bd3e, but I didn't notice it.
-rwxr-xr-x | youtube_dl/YoutubeDL.py | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/youtube_dl/YoutubeDL.py b/youtube_dl/YoutubeDL.py index a68b24ab4..6ac85f4e7 100755 --- a/youtube_dl/YoutubeDL.py +++ b/youtube_dl/YoutubeDL.py @@ -1486,16 +1486,9 @@ class YoutubeDL(object): pps_chain.extend(ie_info['__postprocessors']) pps_chain.extend(self._pps) for pp in pps_chain: - keep_video = None old_filename = info['filepath'] try: - keep_video_wish, info = pp.run(info) - if keep_video_wish is not None: - if keep_video_wish: - keep_video = keep_video_wish - elif keep_video is None: - # No clear decision yet, let IE decide - keep_video = keep_video_wish + keep_video, info = pp.run(info) except PostProcessingError as e: self.report_error(e.msg) if keep_video is False and not self.params.get('keepvideo', False): |