aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAshish Gupta <39122144+Ashish0804@users.noreply.github.com>2021-09-28 16:06:31 +0530
committerGitHub <noreply@github.com>2021-09-28 16:06:31 +0530
commit80c360d7aad7ccda48ccd13be62dbb6fc5a6f128 (patch)
tree4f957f5e07cabdf24ff8c49ad1ff48c5a55a2b2f
parent250a938de82fb6b023c09ce3d89471c5871ff830 (diff)
downloadhypervideo-pre-80c360d7aad7ccda48ccd13be62dbb6fc5a6f128.tar.lz
hypervideo-pre-80c360d7aad7ccda48ccd13be62dbb6fc5a6f128.tar.xz
hypervideo-pre-80c360d7aad7ccda48ccd13be62dbb6fc5a6f128.zip
[LinkedInLearning] Fix newline bug in subtitles (#1104)
Authored by: Ashish0804
-rw-r--r--yt_dlp/extractor/linkedin.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/yt_dlp/extractor/linkedin.py b/yt_dlp/extractor/linkedin.py
index f47d59a38..3ce906e2f 100644
--- a/yt_dlp/extractor/linkedin.py
+++ b/yt_dlp/extractor/linkedin.py
@@ -94,9 +94,9 @@ class LinkedInLearningIE(LinkedInLearningBaseIE):
for line, (line_dict, next_dict) in enumerate(zip_longest(transcript_lines, transcript_lines[1:])):
start_time, caption = line_dict['transcriptStartAt'] / 1000, line_dict['caption']
end_time = next_dict['transcriptStartAt'] / 1000 if next_dict else duration or start_time + 1
- srt_data += '%d\n%s --> %s\n%s\n' % (line + 1, srt_subtitles_timecode(start_time),
- srt_subtitles_timecode(end_time),
- caption)
+ srt_data += '%d\n%s --> %s\n%s\n\n' % (line + 1, srt_subtitles_timecode(start_time),
+ srt_subtitles_timecode(end_time),
+ caption)
return srt_data
def _real_extract(self, url):