Added more functions to index.js