mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-08-10 13:20:33 +02:00
all: eliminate usage of global ProxyLogger
So setting up logging for ctrld binary and ctrld packages could be done more easily, decouple the required setup for interactive vs daemon running. This is the first step toward replacing rs/zerolog libary with a different logging library.
This commit is contained in:
@@ -15,6 +15,7 @@ const merlinNvramCustomClientListKey = "custom_clientlist"
|
||||
|
||||
type merlinDiscover struct {
|
||||
hostname sync.Map // mac => hostname
|
||||
logger *ctrld.Logger
|
||||
}
|
||||
|
||||
func (m *merlinDiscover) refresh() error {
|
||||
@@ -25,7 +26,7 @@ func (m *merlinDiscover) refresh() error {
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
ctrld.ProxyLogger.Load().Debug().Msg("reading Merlin custom client list")
|
||||
m.logger.Debug().Msg("reading Merlin custom client list")
|
||||
m.parseMerlinCustomClientList(out)
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user