diff --git a/src/utils/getVideoDetails.ts b/src/utils/getVideoDetails.ts index 251336f..3d861ed 100644 --- a/src/utils/getVideoDetails.ts +++ b/src/utils/getVideoDetails.ts @@ -46,7 +46,10 @@ async function newLeafWrapper(videoId: string, ignoreCache: boolean) { export function getVideoDetails(videoId: string, ignoreCache = false): Promise { if (!config.newLeafURLs) { return getPlayerData(videoId, ignoreCache) - .then(data => convertFromInnerTube(data)); + .then(data => convertFromInnerTube(data)) + .catch(() => { + return null; + }); } return Promise.any([ newLeafWrapper(videoId, ignoreCache)