diff --git a/bin/monitor.js b/bin/monitor.js
index 1f0e420db88042a79e2d3851e3af60fac30f81f4..0e84360244649e9826ed43312676c81426b91a92 100755
--- a/bin/monitor.js
+++ b/bin/monitor.js
@@ -61,7 +61,7 @@ function    dnspeercachelookup()
                 var     enode   =   json.Answer[i].data;
                 // strip quotes
                 if ( enode.substring(0,1) == '"' && enode.substring(enode.length-1) == '"' )
-                    enode       =   enode.substring(1,enode.length-2);
+                    enode       =   enode.substring(1,enode.length-1);
                 console.log(
                     "We have no peers, so will try to connect to "
                     + enode