Make ops tool work in production mode
This commit is contained in:
@@ -18,12 +18,11 @@ class AddUserTool {
|
||||
}
|
||||
|
||||
async run() {
|
||||
const mongoUri = config.get('uri.mongo')
|
||||
|
||||
try {
|
||||
const mongoUri = config.get('uri.mongo')
|
||||
const db = await new DB().connect(mongoUri)
|
||||
|
||||
console.log(`Connected to MongoDB at ${mongoUri}`)
|
||||
console.log(`Connected to MongoDB at '${mongoUri}'`)
|
||||
|
||||
const User = db.User
|
||||
let user = new User({
|
||||
|
||||
Reference in New Issue
Block a user