mirror of
https://github.com/lightninglabs/loop
synced 2024-11-11 13:11:12 +00:00
loopd/daemon: handle proxy error
Check returned error to make linter happy.
This commit is contained in:
parent
2334816a59
commit
391ae9dc6b
@ -103,7 +103,15 @@ func daemon(config *config) error {
|
|||||||
}
|
}
|
||||||
defer restListener.Close()
|
defer restListener.Close()
|
||||||
proxy := &http.Server{Handler: mux}
|
proxy := &http.Server{Handler: mux}
|
||||||
go proxy.Serve(restListener)
|
|
||||||
|
go func() {
|
||||||
|
err := proxy.Serve(restListener)
|
||||||
|
// ErrServerClosed is always returned when the proxy is shut
|
||||||
|
// down, so don't log it.
|
||||||
|
if err != nil && err != http.ErrServerClosed {
|
||||||
|
log.Error(err)
|
||||||
|
}
|
||||||
|
}()
|
||||||
|
|
||||||
statusChan := make(chan loop.SwapInfo)
|
statusChan := make(chan loop.SwapInfo)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user