const register = async (ctx, next) => {
console.log(123)
const opts = ctx.request.body
const newUser = await user.save(opts)
console.log(newUser)
}
123 can be printed, and new User can also print, and then it stops when it comes to the save method. There is no response? ?
How is this going? ?
Looked at issues https://github.com/Automattic... Still not solved? ? what to do? ?
女神的闺蜜爱上我2017-07-04 13:46:14
Axiba is the reason for the mongodb connection, just put the code directly at the top
const mongoose = require('mongoose')
mongoose.Promise = require('bluebird')
mongoose.connect('mongodb://localhost/blog')