Handle deferred stop error

This commit is contained in:
Samuel Hawksby-Robinson 2023-06-02 11:32:58 +01:00
parent 5cf2038d32
commit e620633eb7
2 changed files with 7 additions and 2 deletions

View File

@ -1 +1 @@
0.154.3
0.154.4

View File

@ -11,6 +11,8 @@ import (
"sync"
"time"
"go.uber.org/zap"
"github.com/status-im/status-go/logutils"
"github.com/status-im/status-go/protocol/common"
"github.com/status-im/status-go/server"
@ -134,7 +136,10 @@ func CheckOutbound() error {
return err
}
defer func() {
stop()
err := stop()
if err != nil {
logutils.ZapLogger().Error("error while stopping preflight serve", zap.Error(err))
}
}()
// Client stuff