Fix getSubs import
This commit is contained in:
parent
212e17a189
commit
c7763eddd1
|
@ -61,6 +61,7 @@ function getYoutubeDLSubs (url: string, opts?: object): Promise<YoutubeDLSubs> {
|
||||||
.then(youtubeDL => {
|
.then(youtubeDL => {
|
||||||
youtubeDL.getSubs(url, options, (err, files) => {
|
youtubeDL.getSubs(url, options, (err, files) => {
|
||||||
if (err) return rej(err)
|
if (err) return rej(err)
|
||||||
|
if (!files) return []
|
||||||
|
|
||||||
logger.debug('Get subtitles from youtube dl.', { url, files })
|
logger.debug('Get subtitles from youtube dl.', { url, files })
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue