email config added to production mode, document ready added to js