rm unnecessary modularization of main function; make jshint happy