Searches called from api.go, various other tweaks, searches now have a callback for success/failure, node ID now reported by admin socket

This commit is contained in:
Neil Alexander 2019-04-18 23:38:23 +01:00
parent eef2a02d0a
commit 160e01e84f
No known key found for this signature in database
GPG key ID: A02A2019A2BB0944
7 changed files with 177 additions and 81 deletions

View file

@ -277,6 +277,9 @@ func main() {
fmt.Println("Coords:", coords)
}
if *verbose {
if nodeID, ok := v.(map[string]interface{})["node_id"].(string); ok {
fmt.Println("Node ID:", nodeID)
}
if boxPubKey, ok := v.(map[string]interface{})["box_pub_key"].(string); ok {
fmt.Println("Public encryption key:", boxPubKey)
}