Skip to content

Commit

Permalink
fix: Tautulli recent on show/Season
Browse files Browse the repository at this point in the history
- it would have not created an poster if someone only uses show poster.
  • Loading branch information
fscorrupt committed Dec 3, 2024
1 parent f286b39 commit 909745c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
10 changes: 9 additions & 1 deletion Posterizarr.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ param (
[switch]$SyncEmby
)

$CurrentScriptVersion = "1.9.11"
$CurrentScriptVersion = "1.9.12"
$global:HeaderWritten = $false
$ProgressPreference = 'SilentlyContinue'

Expand Down Expand Up @@ -8187,6 +8187,14 @@ Elseif ($Tautulli) {
$contentquery = "video"
$queryKey = $RatingKey
}
Elseif ($mediatype -eq 'show') {
$contentquery = "Directory"
$queryKey = $RatingKey
}
Elseif ($mediatype -eq 'season') {
$contentquery = "Directory"
$queryKey = $parentratingkey
}
Else {
$contentquery = "Directory"
$queryKey = if ($grandparentratingkey) { $grandparentratingkey }Else { $parentratingkey }
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ To use it we need to configure a script in Tautulli, please follow these instruc
1. Next go to Arguments -> Unfold `Recently Added` Menu and paste the following Argument, after that you can save it.
- **Please do not change the Argument otherwise the script could fail.**
```sh
<movie>RatingKey "{rating_key}" mediatype "{media_type}"</movie><show>grandparentratingkey "{grandparent_rating_key}" mediatype "{media_type}"</show><season>parentratingkey "{parent_rating_key}" grandparentratingkey "{grandparent_rating_key}" mediatype "{media_type}"</season><episode>RatingKey "{rating_key}" parentratingkey "{parent_rating_key}" grandparentratingkey "{grandparent_rating_key}" mediatype "{media_type}"</episode>
<movie>RatingKey "{rating_key}" mediatype "{media_type}"</movie><show>RatingKey "{rating_key}" mediatype "{media_type}"</show><season>parentratingkey "{parent_rating_key}" mediatype "{media_type}"</season><episode>RatingKey "{rating_key}" parentratingkey "{parent_rating_key}" grandparentratingkey "{grandparent_rating_key}" mediatype "{media_type}"</episode>
```
<details close>
<summary>🖼️Example [click to unfold]</summary>
Expand Down Expand Up @@ -536,7 +536,7 @@ In this mode we use Tautulli to trigger Posterizarr for an specific item in Plex
1. Next go to Arguments -> Unfold `Recently Added` Menu and paste the following Argument, after that you can save it.
- **Please do not change the Argument otherwise the script could fail.**
```sh
<movie>-Tautulli -RatingKey "{rating_key}" -mediatype "{media_type}"</movie><show>-Tautulli -grandparentratingkey "{grandparent_rating_key}" -mediatype "{media_type}"</show><season>-Tautulli -parentratingkey "{parent_rating_key}" -grandparentratingkey "{grandparent_rating_key}" -mediatype "{media_type}"</season><episode>-Tautulli -RatingKey "{rating_key}" -parentratingkey "{parent_rating_key}" -grandparentratingkey "{grandparent_rating_key}" -mediatype "{media_type}"</episode>
<movie>RatingKey "{rating_key}" mediatype "{media_type}"</movie><show>RatingKey "{rating_key}" mediatype "{media_type}"</show><season>parentratingkey "{parent_rating_key}" mediatype "{media_type}"</season><episode>RatingKey "{rating_key}" parentratingkey "{parent_rating_key}" grandparentratingkey "{grandparent_rating_key}" mediatype "{media_type}"</episode>
```
<details close>
<summary>🖼️Example [click to unfold]</summary>
Expand Down
2 changes: 1 addition & 1 deletion Release.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.9.11
1.9.12

0 comments on commit 909745c

Please sign in to comment.