mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 08:49:13 +00:00
fix: lidarr add more info to push (#133)
This commit is contained in:
parent
bcc9fad509
commit
6d68a5c3b7
1 changed files with 7 additions and 0 deletions
|
@ -2,6 +2,7 @@ package action
|
|||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
"github.com/autobrr/autobrr/internal/domain"
|
||||
|
@ -52,6 +53,12 @@ func (s *service) lidarr(release domain.Release, action domain.Action) ([]string
|
|||
PublishDate: time.Now().Format(time.RFC3339),
|
||||
}
|
||||
|
||||
// special handling for RED and OPS because their torrent names contain to little info
|
||||
// "Artist - Album" is not enough for Lidarr to make a decision. It needs year like "Artist - Album 2022"
|
||||
if release.Indexer == "redacted" || release.Indexer == "ops" {
|
||||
r.Title = fmt.Sprintf("%v (%d)", release.TorrentName, release.Year)
|
||||
}
|
||||
|
||||
rejections, err := arr.Push(r)
|
||||
if err != nil {
|
||||
log.Error().Stack().Err(err).Msgf("lidarr: failed to push release: %v", r)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue