Node.js dns.resolve versus dns.lookup over VPN connections

I've been working on an application lately that uses Node.js APIs. It's an internal application for Emma and needed access to one of our internal domains, Since we have some employees working remotely this application also needed to work over VPN connection. After doing some research I discovered a mthod within the DNS module called dns.resolve. In my tests locally this method would properly return a success status when attempting to connect to our file server.

var dataDomain = '',
    dns = require("dns");

dns.lookup(dataDomain, function(error, addr){

It turns out that I should have been using dns.lookup instead. Apparently dns.resolve uses internal DNS infrastructure which VPN connections interfere with. The dns.lookup method uses the operating system's getHostName architecture instead.