Corrected defines import

parent 061089ee
......@@ -11,8 +11,6 @@ mongoose.Promise = global.Promise;
module.exports.connection = null;
module.exports.defines = require('./defines')
module.exports = (connectionUri, relaxed) => {
if (relaxed === undefined)
mongoose.relaxed = true;
......@@ -27,6 +25,7 @@ module.exports = (connectionUri, relaxed) => {
return mongoose.createConnection(connectionUri, {useNewUrlParser: true, poolSize: 25})
.then(connection => {
module.exports = {};
module.exports.defines = require('./defines')
mongoose.connection = connection;
module.exports.connection = connection;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment