Making index.js passing JSLint
Adding the sync versions of the methods