From 568ee3e8d25d110127912f6220d4300d45021b67 Mon Sep 17 00:00:00 2001 From: nuomi1 Date: Wed, 5 Oct 2022 01:24:53 +0800 Subject: [PATCH] fix: remove query and fragment --- src/you_get/extractors/missevan.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/you_get/extractors/missevan.py b/src/you_get/extractors/missevan.py index 31fbbd62..6d9533ce 100644 --- a/src/you_get/extractors/missevan.py +++ b/src/you_get/extractors/missevan.py @@ -25,6 +25,7 @@ SOFTWARE. import json import os import re +import urllib.parse from ..common import get_content, urls_size, log, player, dry_run from ..extractor import VideoExtractor @@ -99,7 +100,8 @@ def is_covers_stream(stream): return stream.lower() in ('covers', 'coversmini') def get_file_extension(file_path, default=''): - _, suffix = os.path.splitext(file_path) + url_parse_result = urllib.parse.urlparse(file_path) + _, suffix = os.path.splitext(url_parse_result.path) if suffix: # remove dot suffix = suffix[1:]