nyaa: fix sonarr compatibility conflict with radarr year compability (#15640)

This commit is contained in:
Bogdan 2024-10-09 18:29:32 +03:00 committed by GitHub
parent a89820af21
commit 9c7c274623
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 1 deletions

View File

@ -197,7 +197,7 @@ search:
text: "{{ or (.Result.title_phase1) (.Result.title_default) }}" text: "{{ or (.Result.title_phase1) (.Result.title_default) }}"
filters: filters:
- name: re_replace - name: re_replace
args: ["^(\\[.+?\\] ?)?(\\[.+?\\] ?)?(.+?)(\\[)", "$1$2$3{{ if .Config.radarr_compatibility }} {{ .Result.title_keyword_year }} $4{{ else }}$4{{ end }}"] args: ["^(\\[.+?\\] ?)?(\\[.+?\\] ?)?(.+?)(\\[)", "$1$2$3{{ if and (.Config.radarr_compatibility) (.Result.title_keyword_year) }} {{ .Result.title_keyword_year }} $4{{ else }}$4{{ end }}"]
title_phase3: title_phase3:
text: "{{ .Result.title_phase2 }}" text: "{{ .Result.title_phase2 }}"
filters: filters:
@ -229,6 +229,9 @@ search:
args: ["(?i)\\b(?:S\\s|Seasons?\\s?)(\\d+(?:-\\d+)?)\\b(?!(?:-\\d+)?\\s(?:EP|Episodes?)?\\s?(?:\\d+(?:-\\d+)?)?\\s?S\\d+(?:E\\d+(?:-\\d+)?)?)", "$0 S$1"] args: ["(?i)\\b(?:S\\s|Seasons?\\s?)(\\d+(?:-\\d+)?)\\b(?!(?:-\\d+)?\\s(?:EP|Episodes?)?\\s?(?:\\d+(?:-\\d+)?)?\\s?S\\d+(?:E\\d+(?:-\\d+)?)?)", "$0 S$1"]
- name: re_replace - name: re_replace
args: ["(?i)\\b(?:EP|Episodes?)\\s?(\\d+(?:-\\d+)?)\\b(?!(?:-\\d+)?\\sS\\d+(?:-\\d+)?(?:E\\d+(?:-\\d+)?)?)", "$0 S01E$1"] args: ["(?i)\\b(?:EP|Episodes?)\\s?(\\d+(?:-\\d+)?)\\b(?!(?:-\\d+)?\\sS\\d+(?:-\\d+)?(?:E\\d+(?:-\\d+)?)?)", "$0 S01E$1"]
- name: re_replace
args: ["\\s+", " "]
- name: trim
title_has_season: title_has_season:
text: "{{ .Result.title_phase3 }}" text: "{{ .Result.title_phase3 }}"
filters: filters: