removed some unnecessary code and added some comments for whoever picks up the code in order to work on the index.js