updated scripts.js file