aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/postprocessor/modify_chapters.py
diff options
context:
space:
mode:
authorJesús <heckyel@hyperbola.info>2021-11-27 13:25:01 -0500
committerJesús <heckyel@hyperbola.info>2021-11-27 13:25:01 -0500
commitc6df1db4745c9d399204876bbe04e8a311c01df1 (patch)
treea9f4ffa1db45e367aba1de858ac536b761f192fb /yt_dlp/postprocessor/modify_chapters.py
parent5bb25093eb718346ab8a723d2c04f0066fc3958a (diff)
parent93e597ba287539643851f0ad5c5ff04760380268 (diff)
downloadhypervideo-pre-c6df1db4745c9d399204876bbe04e8a311c01df1.tar.lz
hypervideo-pre-c6df1db4745c9d399204876bbe04e8a311c01df1.tar.xz
hypervideo-pre-c6df1db4745c9d399204876bbe04e8a311c01df1.zip
updated from upstream | 27/11/2021 at 13:25
Diffstat (limited to 'yt_dlp/postprocessor/modify_chapters.py')
-rw-r--r--yt_dlp/postprocessor/modify_chapters.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/yt_dlp/postprocessor/modify_chapters.py b/yt_dlp/postprocessor/modify_chapters.py
index dca876200..0728bdcf5 100644
--- a/yt_dlp/postprocessor/modify_chapters.py
+++ b/yt_dlp/postprocessor/modify_chapters.py
@@ -38,7 +38,7 @@ class ModifyChaptersPP(FFmpegPostProcessor):
if not chapters and not sponsor_chapters:
return [], info
- real_duration = self._get_real_video_duration(info)
+ real_duration = self._get_real_video_duration(info['filepath'])
if not chapters:
chapters = [{'start_time': 0, 'end_time': real_duration, 'title': info['title']}]
@@ -72,7 +72,6 @@ class ModifyChaptersPP(FFmpegPostProcessor):
os.replace(out_file, in_file)
files_to_remove.append(uncut_file)
- info['_real_duration'] = info['chapters'][-1]['end_time']
return files_to_remove, info
def _mark_chapters_to_remove(self, chapters, sponsor_chapters):