mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 00:39:13 +00:00
fix(download-clients): qbit nil logger panic (#344)
The logger wasn't set, so it was always nil. Change to always initialize and override if one is passed.
This commit is contained in:
parent
33e3691737
commit
401c93a657
5 changed files with 72 additions and 39 deletions
|
@ -36,7 +36,7 @@ type service struct {
|
|||
clientSvc download_client.Service
|
||||
bus EventBus.Bus
|
||||
|
||||
qbitClients map[qbitKey]*qbittorrent.Client
|
||||
qbitClients map[qbitKey]qbittorrent.Client
|
||||
}
|
||||
|
||||
func NewService(log logger.Logger, repo domain.ActionRepo, clientSvc download_client.Service, bus EventBus.Bus) Service {
|
||||
|
@ -45,7 +45,7 @@ func NewService(log logger.Logger, repo domain.ActionRepo, clientSvc download_cl
|
|||
repo: repo,
|
||||
clientSvc: clientSvc,
|
||||
bus: bus,
|
||||
qbitClients: map[qbitKey]*qbittorrent.Client{},
|
||||
qbitClients: map[qbitKey]qbittorrent.Client{},
|
||||
}
|
||||
|
||||
s.subLogger = zstdlog.NewStdLoggerWithLevel(s.log.With().Logger(), zerolog.TraceLevel)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue