Skip to content

Commit

Permalink
Proof of concept: support delegating deferredOpen
Browse files Browse the repository at this point in the history
  • Loading branch information
vweevers committed Sep 22, 2019
1 parent 90a1b4e commit dc5cdb7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/levelup.js
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down

0 comments on commit dc5cdb7

Please sign in to comment.