setUp: function(next) { this.eventEmitter = new EventEmitter(); var vfs = vfsLocal({ root: "/" }); this.factory = node.factory(vfs, home); async.makePath(home, next); },
this.initialize = function() { /* * Make sure you specify a directory for your files. If you don't, we will * use the system's temp directory instead, and you might not want that. */ this.dataDir = this.handler.server.tmpDir + "/jsdav"; // ensure that the path is there Async.makePath(this.dataDir, function() {}); this.handler.addEventListener("beforeMethod", this.beforeMethod.bind(this)); this.handler.addEventListener("beforeCreateFile", this.beforeCreateFile.bind(this)); };
initialize: function(dataDir) { this.dataDir = dataDir || jsDAV_Server.DEFAULT_TMPDIR + "/jsdav"; // ensure that the path is there Async.makePath(this.dataDir, function() {}); },
async.rmtree(this.home, function (err) { if (err) return next(err); async.makePath(_self.home, next); });