These are chat archives for Automattic/mongoose

5th
Feb 2018
Ambika Kumar
@ambikarajbadal
Feb 05 2018 10:13
when I write this code then i get error..
mongoose.connect('mongodb://localhost/webapp',{
useMongoClient: true;
});
Can anybody help me?
Kev
@lineus
Feb 05 2018 10:35
what error do you get @ambikarajbadal ?
Ambika Kumar
@ambikarajbadal
Feb 05 2018 10:36
SyntaxError: Unexpected token ;
at new Script (vm.js:51:7)
at createScript (vm.js:138:10)
at Object.runInThisContext (vm.js:199:10)
at Module._compile (module.js:624:28)
at Object.Module._extensions..js (module.js:671:10)
at Module.load (module.js:573:32)
at tryModuleLoad (module.js:513:12)
at Function.Module._load (module.js:505:3)
at Function.Module.runMain (module.js:701:10)
at startup (bootstrap_node.js:190:16)
[nodemon] app crashed - waiting for file changes before starting...
@lineus
Kev
@lineus
Feb 05 2018 10:37
useMongoClient: true; should be useMongoClient: true
you're inside an object literal there
Ambika Kumar
@ambikarajbadal
Feb 05 2018 10:39
Yeah problem solved Thanks @lineus
Kev
@lineus
Feb 05 2018 10:39
no worries @ambikarajbadal !
Anjan Das
@bugToaster
Feb 05 2018 17:25
thanks @lineus