refactored to new config js file