Unhandled Promise Rejection Error in node js
问题 am getting error while executing combined queries Am using, sequelize and mysql Here is my code: const makeAuthenticate = async (req, res) => { const newOtp = Math.floor(100000 + Math.random() * 900000); try { const {phone} = req.body; const [user, created] = await db.User.findOrCreate({ where: { phone: phone }, }) .then(e => { db.User.update({ otp: newOtp }, { where: { phone: phone }}) .then(f => res.status(200).json({ otp: newOtp })) .catch(err => res.status(500).json({error: err})) //