changes in function.js