[fix] register email confirmation
This commit is contained in:
parent
aa63c3e7bd
commit
b52d3a46a2
1 changed files with 2 additions and 2 deletions
|
@ -229,11 +229,11 @@ const userController = {
|
|||
|
||||
if (!req.body.password) { delete req.body.password }
|
||||
|
||||
await user.update(req.body)
|
||||
|
||||
if (!user.is_active && req.body.is_active && user.recover_code) {
|
||||
mail.send(user.email, 'confirm', { user, config })
|
||||
}
|
||||
|
||||
await user.update(req.body)
|
||||
res.json(user)
|
||||
},
|
||||
|
||||
|
|
Loading…
Reference in a new issue