Fixed mail bug in index.js file in mail folder