Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function defaultCallback(error) {
if (error) {
console.error(error.stack.toString());
} else {
console.log(
'hops: Server listening at ' +
url.format({
protocol: hopsConfig.https ? 'https' : 'http',
hostname:
hopsConfig.host === '0.0.0.0' ? 'localhost' : hopsConfig.host,
port: hopsConfig.port,
pathname: hopsConfig.basePath,
})
);
}
}