Browse Source

added logs and create node update

0xdcarns 3 years ago
parent
commit
a622afc4c1
1 changed files with 6 additions and 1 deletions
  1. 6 1
      netclient/functions/daemon.go

+ 6 - 1
netclient/functions/daemon.go

@@ -215,7 +215,12 @@ func NodeUpdate(client mqtt.Client, msg mqtt.Message) {
 				}
 				}
 			}
 			}
 		}
 		}
-		publishClientPeers(&cfg)
+		pubErr := publishClientPeers(&cfg)
+		if pubErr != nil {
+			ncutils.Log("could not notify server to update peers after interface change")
+		} else {
+			ncutils.Log("signalled peer update to server")
+		}
 	}
 	}
 	//deal with DNS
 	//deal with DNS
 	if newNode.DNSOn != "yes" && shouldDNSChange && cfg.Node.Interface != "" {
 	if newNode.DNSOn != "yes" && shouldDNSChange && cfg.Node.Interface != "" {