Fixed some bugs, moved to index.js
Removing logging