mirror of
https://github.com/spaam/svtplay-dl.git
synced 2024-11-27 13:44:14 +01:00
pluto.tv: remove support for subtitles
This commit is contained in:
parent
9b768832d4
commit
c587004ecd
@ -8,6 +8,7 @@ from svtplay_dl.error import ServiceError
|
|||||||
from svtplay_dl.fetcher.hls import hlsparse
|
from svtplay_dl.fetcher.hls import hlsparse
|
||||||
from svtplay_dl.service import OpenGraphThumbMixin
|
from svtplay_dl.service import OpenGraphThumbMixin
|
||||||
from svtplay_dl.service import Service
|
from svtplay_dl.service import Service
|
||||||
|
from svtplay_dl.subtitle import subtitle
|
||||||
|
|
||||||
|
|
||||||
class Plutotv(Service, OpenGraphThumbMixin):
|
class Plutotv(Service, OpenGraphThumbMixin):
|
||||||
@ -55,7 +56,7 @@ class Plutotv(Service, OpenGraphThumbMixin):
|
|||||||
yield ServiceError("Can't find video info")
|
yield ServiceError("Can't find video info")
|
||||||
return
|
return
|
||||||
|
|
||||||
yield from hlsparse(
|
playlists = hlsparse(
|
||||||
self.config,
|
self.config,
|
||||||
self.http.request("get", HLSplaylist, headers={"Authorization": f"Bearer {self.sessionToken}"}),
|
self.http.request("get", HLSplaylist, headers={"Authorization": f"Bearer {self.sessionToken}"}),
|
||||||
HLSplaylist,
|
HLSplaylist,
|
||||||
@ -63,6 +64,12 @@ class Plutotv(Service, OpenGraphThumbMixin):
|
|||||||
filter=True,
|
filter=True,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
for playlist in playlists:
|
||||||
|
if self.config.get("subtitle") and isinstance(playlist, subtitle):
|
||||||
|
logging.warning("Subtitles are no longer supported for pluto.tv")
|
||||||
|
continue
|
||||||
|
yield playlist
|
||||||
|
|
||||||
def find_all_episodes(self, options):
|
def find_all_episodes(self, options):
|
||||||
episodes = []
|
episodes = []
|
||||||
self.data = self.get_urldata()
|
self.data = self.get_urldata()
|
||||||
|
Loading…
Reference in New Issue
Block a user