updated main js file