fix(sonarr): Pass the series ID and season number alongside all TriggerAutomaticSeasonSearch events when publishing to the networking channel

This commit is contained in:
2024-12-18 01:34:45 -07:00
parent b12c635c27
commit ed645dd0d5
6 changed files with 46 additions and 128 deletions
@@ -94,7 +94,7 @@ impl<'a, 'b> CliCommandHandler<'a, 'b, SonarrTriggerAutomaticSearchCommand>
let resp = self
.network
.handle_network_event(
SonarrEvent::TriggerAutomaticSeasonSearch(Some((series_id, season_number))).into(),
SonarrEvent::TriggerAutomaticSeasonSearch((series_id, season_number)).into(),
)
.await?;
serde_json::to_string_pretty(&resp)?
@@ -197,11 +197,8 @@ mod tests {
mock_network
.expect_handle_network_event()
.with(eq::<NetworkEvent>(
SonarrEvent::TriggerAutomaticSeasonSearch(Some((
expected_series_id,
expected_season_number,
)))
.into(),
SonarrEvent::TriggerAutomaticSeasonSearch((expected_series_id, expected_season_number))
.into(),
))
.times(1)
.returning(|_| {