main.js code cleanup for presenting