returned dispatch error from the node

This commit is contained in:
StephenButtolph 2020-06-02 15:26:30 -04:00
parent 1daaa5fdaa
commit 18e11359af
2 changed files with 5 additions and 4 deletions

View File

@ -81,6 +81,7 @@ func main() {
defer node.Shutdown()
log.Debug("Dispatching node handlers")
node.Dispatch()
log.Debug("dispatching node handlers")
err = node.Dispatch()
log.Debug("node dispatching returned with %s", err)
}

View File

@ -195,7 +195,7 @@ func (i *insecureValidatorManager) Disconnected(vdrID ids.ShortID) bool {
// Dispatch starts the node's servers.
// Returns when the node exits.
func (n *Node) Dispatch() {
func (n *Node) Dispatch() error {
// Add bootstrap nodes to the peer network
for _, peer := range n.Config.BootstrapPeers {
if !peer.IP.Equal(n.Config.StakingIP) {
@ -205,7 +205,7 @@ func (n *Node) Dispatch() {
}
}
n.Net.Dispatch()
return n.Net.Dispatch()
}
/*