mirror of
https://github.com/YuzuZensai/play-dl-test.git
synced 2026-01-31 14:58:05 +00:00
Added URL support for the Video Music properties with typings
This commit is contained in:
@@ -223,7 +223,7 @@ export async function video_basic_info(url: string, options: InfoOptions = {}):
|
||||
let url = x.metadataRowRenderer.contents[0]?.runs?.[0]?.navigationEndpoint?.commandMetadata?.webCommandMetadata.url;
|
||||
if (title.toLowerCase() === 'song') {
|
||||
music.push({});
|
||||
music[music.length - 1].song = url ? {text, url: `https://www.youtube.com${url}`} : text;
|
||||
music[music.length - 1].song = {text, url: url ? `https://www.youtube.com${url}` : undefined};
|
||||
} else if (music.length === 0) return;
|
||||
else {
|
||||
music[music.length - 1][title.toLowerCase()] = url ? {text, url: `https://www.youtube.com${url}`} : text;
|
||||
|
||||
Reference in New Issue
Block a user