Skip to content

Commit

Permalink
fix issue with v6.0.0
Browse files Browse the repository at this point in the history
I have some `Error: Missing/invalid DB name` error thrown when using the latest release of pouchdb.
This PR should fix this issue.

For reference: pouchdb/pouchdb#5435.
  • Loading branch information
oliviertassinari authored and nolanlawson committed Sep 12, 2016
1 parent b7f195f commit ce46d63
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ exports.plugin.dump = utils.toPromise(function (writableStream, opts, callback)

var PouchDB = self.constructor;

var output = new PouchDB(self._db_name, {
var output = new PouchDB(self.name, {
adapter: 'writableStream'
});
output.setupStream(writableStream);
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@
},
"dependencies": {
"argsarray": "0.0.1",
"inherits": "~2.0.1",
"ndjson": "^1.4.3",
"inherits": "^2.0.3",
"lodash.pick": "^4.0.0",
"pouchdb-promise": "^5.4.4",
"ndjson": "^1.4.3",
"pouch-stream": "^0.4.0",
"pouchdb-promise": "^6.0.4",
"through2": "^2.0.0"
},
"devDependencies": {
Expand All @@ -59,7 +59,7 @@
"mocha": "~1.18",
"noms": "0.0.0",
"phantomjs": "^1.9.7-5",
"pouchdb-memory": "^1.0.0",
"pouchdb-memory": "^6.0.0",
"random-document-stream": "0.0.0",
"request": "^2.36.0",
"sauce-connect-launcher": "^0.4.2",
Expand Down
4 changes: 2 additions & 2 deletions test/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,9 +56,9 @@ function tests(dbName, dbType) {
next(null, null);
});
db = new Pouch(dbName);
return db.then(function () {
return db.info().then(function () {
remote = new Pouch(dbName + '_remote');
return remote.then(function () {});
return remote.info().then(function () {});
});
});

Expand Down

0 comments on commit ce46d63

Please sign in to comment.