Skip to content

Commit

Permalink
FIX: Inline trailers not detected in Series
Browse files Browse the repository at this point in the history
  • Loading branch information
nandyalu committed Feb 5, 2025
1 parent e4bd627 commit bc0fe59
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions backend/core/base/connection_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class BaseConnectionManager(ABC):

arr_manager: ArrManagerProtocol
connection_id: int
inline_trailer: bool
# inline_trailer: bool
is_movie: bool
monitor: MonitorType
parse_media: Callable[[int, dict[str, Any]], MediaCreate]
Expand All @@ -51,7 +51,7 @@ def __init__(
connection: ConnectionRead,
arr_manager: ArrManagerProtocol,
parse_media: Callable[[int, dict[str, Any]], MediaCreate],
inline_trailer: bool,
# inline_trailer: bool,
is_movie: bool = True,
):
"""Initialize the ArrConnectionManager. \n
Expand All @@ -62,7 +62,7 @@ def __init__(
self.monitor = connection.monitor
self.arr_manager = arr_manager
self.parse_media = parse_media
self.inline_trailer = inline_trailer
# self.inline_trailer = inline_trailer
self.is_movie = is_movie
self.created_count = 0
self.updated_count = 0
Expand Down Expand Up @@ -198,9 +198,10 @@ async def _check_trailer(self, folder_path: str) -> bool:
folder_path (str): The folder path to check for the trailer.\n
Returns:
bool: True if the trailer exists, False otherwise."""
# Check if there ia a trailer either inline or in a 'Trailers' subfolder
trailer_exists = await FilesHandler.check_trailer_exists(
path=folder_path,
check_inline_file=self.inline_trailer,
check_inline_file=True,
)
return trailer_exists

Expand Down
2 changes: 1 addition & 1 deletion backend/core/radarr/connection_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ def __init__(self, connection: ConnectionRead):
connection,
radarr_manager,
parse_movie,
inline_trailer=True,
# inline_trailer=True,
is_movie=True,
)
2 changes: 1 addition & 1 deletion backend/core/sonarr/connection_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ def __init__(self, connection: ConnectionRead):
connection,
sonarr_manager,
parse_series,
inline_trailer=False,
# inline_trailer=False,
is_movie=False,
)

0 comments on commit bc0fe59

Please sign in to comment.