Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function loadConfig()
{
if ( process.env.DATABASE_URL )
{
config.loadUrl( process.env.DATABASE_URL, argv.env );
}
else
{
config.load( argv.config, argv.env );
}
if ( verbose )
{
var current = config.getCurrent();
var s = JSON.parse( JSON.stringify( current.settings ) );
if ( s.password )
s.password = '******';
log.info( 'Using', current.env, 'settings:', s );
}