mirror of
https://gitea.blesmrt.net/mikaela/scripts.git
synced 2024-11-22 02:59:27 +01:00
myip: resolve6, not 4
This commit is contained in:
parent
06bda324aa
commit
ce79b87fe6
@ -29,11 +29,11 @@ dns.resolve4('myip.opendns.com', function (err, addresses) {
|
|||||||
/*
|
/*
|
||||||
|
|
||||||
// Set DNS servers to OpenDNS IPv6
|
// Set DNS servers to OpenDNS IPv6
|
||||||
var servers4 = dns.setServers(["2620:0:ccc::2", "2620:0:ccd::2"])
|
var servers6 = dns.setServers(["2620:0:ccc::2", "2620:0:ccd::2"])
|
||||||
|
|
||||||
// Check where myip.opendns.com resolves to and I think this is a function
|
// Check where myip.opendns.com resolves to and I think this is a function
|
||||||
// that takes arguments err and addresses.
|
// that takes arguments err and addresses.
|
||||||
dns.resolve4('myip.opendns.com', function (err, addresses) {
|
dns.resolve6('myip.opendns.com', function (err, addresses) {
|
||||||
|
|
||||||
// In case of error throw the error message?
|
// In case of error throw the error message?
|
||||||
if (err) throw err;
|
if (err) throw err;
|
||||||
|
Loading…
Reference in New Issue
Block a user