Changed mkdir to mkdirp