correção da atualização do email sem comentarios

pull/21/head
adriano 2023-04-12 14:46:48 -03:00
parent a2471fd08d
commit ee16d6e7c3
1 changed files with 1 additions and 6 deletions

View File

@ -45,11 +45,6 @@ const UpdateUserService = async ({
const emailExists = await User.findOne({ where: { email: value }, raw: true, attributes: ['email', 'id'] });
console.log('emailExists.email: ', emailExists?.email)
console.log('User.email: ', user.email)
console.log('emailExists.id: ', emailExists?.id)
console.log('User.id: ', user.id)
if (emailExists && user.id != emailExists?.id) {
console.error('The email already exists in another user profile!')