Update index.js

set baseDir to empty string if not set through options