[downloader:ytdl] provide 'filename' metadata (closes #291)
This commit is contained in:
@@ -50,6 +50,8 @@ class YoutubeDLDownloader(DownloaderBase):
|
|||||||
return self._download_video(pathfmt, info_dict)
|
return self._download_video(pathfmt, info_dict)
|
||||||
|
|
||||||
def _download_video(self, pathfmt, info_dict):
|
def _download_video(self, pathfmt, info_dict):
|
||||||
|
if "url" in info_dict:
|
||||||
|
text.nameext_from_url(info_dict["url"], pathfmt.keywords)
|
||||||
pathfmt.set_extension(info_dict["ext"])
|
pathfmt.set_extension(info_dict["ext"])
|
||||||
if pathfmt.exists():
|
if pathfmt.exists():
|
||||||
pathfmt.temppath = ""
|
pathfmt.temppath = ""
|
||||||
|
|||||||
@@ -41,7 +41,6 @@ class ArtstationExtractor(Extractor):
|
|||||||
player = adict["player_embedded"]
|
player = adict["player_embedded"]
|
||||||
url = text.extract(player, 'src="', '"')[0]
|
url = text.extract(player, 'src="', '"')[0]
|
||||||
if not url.startswith(self.root):
|
if not url.startswith(self.root):
|
||||||
text.nameext_from_url(url, asset)
|
|
||||||
yield Message.Url, "ytdl:" + url, asset
|
yield Message.Url, "ytdl:" + url, asset
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user