I'm trying to connect to my database using mongoose and in my console is displaying ' option usefindandmodify is not supproted '. I'm using mongoose 6.0.0
this is my code
mongoose.connect(constants.CONNECTION_URL,
{ useNewUrlParser: true,
useUnifiedTopology: true,
useFindAndModify: false
})
.then(() => app.listen(constants.PORT, () => console.log(`Server Running on Port ${constants.PORT}`)))
.catch((error) => console.log(error.message));
mongoose.Promise = global.Promise;
can someone suggest me how can I get rid of that? is written with white if matters neither green nor red, white.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…