]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/threeqsdn.py
[extractor] Deprecate `_sort_formats`
[yt-dlp.git] / yt_dlp / extractor / threeqsdn.py
index a313a8dfbe6332a0b9c94d6cdf8fdd940777b0a7..b1041902bff290f42a73f1a951b9c41fadf29ac2 100644 (file)
@@ -128,10 +128,6 @@ def _real_extract(self, url):
                         'vcodec': 'none' if height == 0 else None,
                         'width': int(height * aspect) if height and aspect else None,
                     })
-        # It seems like this would be correctly handled by default
-        # However, unless someone can confirm this, the old
-        # behaviour is being kept as-is
-        self._sort_formats(formats, ('res', 'source_preference'))
 
         for subtitle in (config.get('subtitles') or []):
             src = subtitle.get('src')
@@ -153,4 +149,8 @@ def _real_extract(self, url):
             'is_live': live,
             'formats': formats,
             'subtitles': subtitles,
+            # It seems like this would be correctly handled by default
+            # However, unless someone can confirm this, the old
+            # behaviour is being kept as-is
+            '_format_sort_fields': ('res', 'source_preference')
         }