bugfix, create client db not passing config
This commit is contained in:
parent
c770c8f0ec
commit
e575c0b929
|
@ -1,9 +1,9 @@
|
||||||
const CouchDb = require(".")
|
const CouchDb = require(".")
|
||||||
|
|
||||||
module.exports = async clientId => {
|
module.exports = async (config, clientId) => {
|
||||||
await CouchDb.db.create(clientId)
|
await CouchDb.db.create(`client-${clientId}`)
|
||||||
|
|
||||||
const db = CouchDb.db.use(clientId)
|
const db = CouchDb(config).db.use(`client-${clientId}`)
|
||||||
|
|
||||||
await db.insert(
|
await db.insert(
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
const couchdb = require("../../../../db")({ database: "couch" })
|
const couchdb = require("../../../../db")({ database: "couch" })
|
||||||
const createClientDb = require("../../../../db/createClientDb")
|
const createClientDb = require("../../../../db/createClientDb")({
|
||||||
|
database: "couch",
|
||||||
|
})
|
||||||
const CLIENT_DB_ID = "client-testing";
|
const CLIENT_DB_ID = "client-testing";
|
||||||
const TEST_APP_ID = "test-app";
|
const TEST_APP_ID = "test-app";
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue