Cleans up mainIndexController.js