adding comments

This commit is contained in:
afeiszli
2022-02-06 11:43:07 -05:00
parent 7c56420b9f
commit 62d0a6a83a
2 changed files with 5 additions and 2 deletions

View File

@@ -19,7 +19,8 @@ import (
"golang.org/x/crypto/bcrypt"
)
const RELAY_NODE_ERR = "could not find relay for node "
// RELAY_NODE_ERR - error to return if relay node is unfound
const RELAY_NODE_ERR = "could not find relay for node"
// GetNetworkNodes - gets the nodes of a network
func GetNetworkNodes(network string) ([]models.Node, error) {
@@ -508,7 +509,7 @@ func GetNodeRelay(network string, relayedNodeAddr string) (models.Node, error) {
}
}
}
return relay, errors.New(RELAY_NODE_ERR + relayedNodeAddr)
return relay, errors.New(RELAY_NODE_ERR + " " + relayedNodeAddr)
}
// GetNodeByIDorMacAddress - gets the node, if a mac address exists, but not id, then it should delete it and recreate in DB with new ID