Skip to content

Commit

Permalink
fix(errorhandling): Add missing error assertion in executeDB
Browse files Browse the repository at this point in the history
fixes #381
  • Loading branch information
wzrdtales committed Sep 29, 2016
1 parent f8039f3 commit 376fdc3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions api.js
Original file line number Diff line number Diff line change
Expand Up @@ -926,6 +926,8 @@ function executeDB(internals, config, callback) {
}

index.driver(config.getCurrent().settings, function(err, db) {
assert.ifError(err);

if (internals.mode === 'create') {
db.createDatabase(internals.argv.dbname, {
ifNotExists: true
Expand Down

0 comments on commit 376fdc3

Please sign in to comment.