Skip to content

Commit

Permalink
fix tags impl
Browse files Browse the repository at this point in the history
  • Loading branch information
5rahim committed Nov 25, 2024
1 parent 168fe41 commit 7b24505
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions internal/core/modules.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,6 +296,7 @@ func (a *App) InitOrRefreshModules() {
Port: settings.Torrent.QBittorrentPort,
Host: settings.Torrent.QBittorrentHost,
Path: settings.Torrent.QBittorrentPath,
Tags: settings.Torrent.QBittorrentTags,
})
go func() {
if settings.Torrent.Default == "qbittorrent" {
Expand Down
3 changes: 3 additions & 0 deletions internal/torrent_clients/qbittorrent/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ type Client struct {
Host string
Path string
DisableBinaryUse bool
Tags string
Application qbittorrent_application.Client
Log qbittorrent_log.Client
RSS qbittorrent_rss.Client
Expand All @@ -45,6 +46,7 @@ type NewClientOptions struct {
Host string
Path string
DisableBinaryUse bool
Tags string
}

func NewClient(opts *NewClientOptions) *Client {
Expand All @@ -66,6 +68,7 @@ func NewClient(opts *NewClientOptions) *Client {
Path: opts.Path,
DisableBinaryUse: opts.DisableBinaryUse,
Host: opts.Host,
Tags: opts.Tags,
Application: qbittorrent_application.Client{
BaseUrl: baseURL + "/app",
Client: client,
Expand Down
2 changes: 1 addition & 1 deletion internal/torrent_clients/torrent_client/repository.go
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ func (r *Repository) AddMagnets(magnets []string, dest string) error {
case QbittorrentClient:
err = r.qBittorrentClient.Torrent.AddURLs(magnets, &qbittorrent_model.AddTorrentsOptions{
Savepath: dest,
Tags: "Anime,Seanime",
Tags: r.qBittorrentClient.Tags,
})
case TransmissionClient:
for _, magnet := range magnets {
Expand Down

0 comments on commit 7b24505

Please sign in to comment.