Update __init__.py

This commit is contained in:
n0stal6ic
2026-04-08 13:31:01 -05:00
committed by GitHub
parent 5e60d653b4
commit beb943c5f0
+5 -2
View File
@@ -300,7 +300,10 @@ class PBS(Service):
if not r.ok: if not r.ok:
self.log.warning(f"Unable to find specials for '{show_slug}': {r.status_code}.") self.log.warning(f"Unable to find specials for '{show_slug}': {r.status_code}.")
return [] return []
return r.json() return [
sp for sp in r.json()
if sp.get("slug") != sp.get("parent", {}).get("slug")
]
def _fetch_season_episodes(self, show_slug: str, season_cid: str) -> list[dict]: def _fetch_season_episodes(self, show_slug: str, season_cid: str) -> list[dict]:
url = self.config["endpoints"]["show_episodes"].format( url = self.config["endpoints"]["show_episodes"].format(
@@ -334,4 +337,4 @@ class PBS(Service):
try: try:
return int(date_str[:4]) return int(date_str[:4])
except (ValueError, TypeError): except (ValueError, TypeError):
return None return None