Fix getSubs import

pull/2879/head
Chocobozzz 2020-06-16 09:35:18 +02:00
parent 212e17a189
commit c7763eddd1
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
1 changed files with 1 additions and 0 deletions

View File

@ -61,6 +61,7 @@ function getYoutubeDLSubs (url: string, opts?: object): Promise<YoutubeDLSubs> {
.then(youtubeDL => {
youtubeDL.getSubs(url, options, (err, files) => {
if (err) return rej(err)
if (!files) return []
logger.debug('Get subtitles from youtube dl.', { url, files })