diff --git a/app.js b/app.js index 803df97..c38f8bd 100644 --- a/app.js +++ b/app.js @@ -180,9 +180,16 @@ Steppy( logger.log('Server config:', JSON.stringify(app.config, null, 4)); - db.init(app.config.paths.db, { - db: require(app.config.storage.backend) - }, this.slot()); + var dbBackend = require(app.config.storage.backend); + + // monkey patch memdown to allow save empty strings which is correct + // at general but occasionally not allowed at _checkKey + // https://github.com/Level/abstract-leveldown/issues/74 + if (app.config.storage.backend === 'memdown') { + dbBackend.prototype._checkKey = _.noop; + } + + db.init(app.config.paths.db, {db: dbBackend}, this.slot()); }, function() { // load all projects for the first time diff --git a/package.json b/package.json index 333dcf4..575d07f 100644 --- a/package.json +++ b/package.json @@ -62,7 +62,7 @@ "gulp-react-jade-amd": "git://github.com/vladimir-polyakov/gulp-react-jade-amd", "jade": "1.11.0", "main-bower-files": "2.7.0", - "memdown": "1.0.0", + "memdown": "1.1.0", "mocha": "1.18.2", "nci-yaml-reader": "0.1.0", "nodemon": "1.3.7",