Removes old code from main js file