diff --git a/lib/levelup.js b/lib/levelup.js index 880a367d..9d8938e7 100644 --- a/lib/levelup.js +++ b/lib/levelup.js @@ -54,10 +54,10 @@ function LevelUP (db, options, callback) { this.options = getOptions(options) this._db = db - this.db = new DeferredLevelDOWN(db) + this.db = db.supports && db.supports.deferredOpen ? db : new DeferredLevelDOWN(db) this.open(callback) - // Create manifest based on deferred-leveldown's + // Create manifest based on db or deferred-leveldown's this.supports = supports(this.db.supports, { status: false, deferredOpen: true,