Skip to content

Commit

Permalink
Add support for contribution streams movies and series catalogs
Browse files Browse the repository at this point in the history
  • Loading branch information
mhdzumair committed Jan 22, 2025
1 parent 140e97e commit 6b5b9ca
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions api/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,8 @@ def get_cache_key(
if user_data.streaming_provider and "_watchlist_" in catalog_id:
cache_key = None
is_watchlist_catalog = True
elif catalog_id.startswith("contribution_") and user_data.contribution_streams:
cache_key = None
elif catalog_type == "events":
cache_key = None
elif catalog_type in ["movie", "series"]:
Expand Down
2 changes: 2 additions & 0 deletions db/crud.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ async def get_meta_list(
genre: Optional[str] = None,
) -> list[schemas.Meta]:
"""Get a list of metadata entries based on various filters"""
if catalog.startswith("contribution_"):
catalog = "contribution_stream"
poster_path = f"{settings.poster_host_url}/poster/{catalog_type}/"
meta_class = (
MediaFusionMovieMetaData
Expand Down
2 changes: 2 additions & 0 deletions resources/templates/manifest.json.j2
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@
"fighting": {"type": "movie", "name": "Fighting (WWE, UFC)", "genres": ["WWE", "UFC"]},
"tgx_movie": {"type": "movie", "name": "TGx Movies"},
"tgx_series": {"type": "series", "name": "TGx Series"},
"contribution_movies": {"type": "movie", "name": "Contribution Movies"},
"contribution_series": {"type": "series", "name": "Contribution Series"},
"other_sports": {"type": "movie", "name": "Other Sports", "genres": []},
"live_sport_events": {"type": "events", "name": "Live Sport Events", "genres": ["American Football", "Athletics", "Aussie Rules", "Baseball", "Basketball", "Bowling", "Boxing", "Cricket", "Cycling", "Dart", "Floorball", "Football", "Futsal", "GAA", "Golf", "Gymnastics", "Handball", "Hockey", "Horse Racing", "Lacrosse", "MMA", "Motor Sport", "Netball", "Other Sports", "Rugby/AFL", "Squash", "Tennis", "Volleyball"]},
"prowlarr_movies": {"type": "movie", "name": "Prowlarr Scraped Movies"},
Expand Down
2 changes: 2 additions & 0 deletions utils/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@
"fighting": "Fighting (WWE, UFC)",
"tgx_movie": "TGx Movies",
"tgx_series": "TGx Series",
"contribution_movies": "Contribution Streams Movies",
"contribution_series": "Contribution Streams Series",
}

USER_UPLOAD_SUPPORTED_MOVIE_CATALOG_IDS = [
Expand Down

0 comments on commit 6b5b9ca

Please sign in to comment.