Correção da atualização do contato

pull/20/head
adriano 2023-04-18 18:02:43 -03:00
parent 5c13bbffb6
commit 3aa4a62b5a
1 changed files with 1 additions and 1 deletions

View File

@ -70,7 +70,7 @@ const UpdateContactService = async ({
where: { number }
});
if (numberExists) {
if (numberExists && numberExists.id != +contactId) {
throw new AppError("ERR_DUPLICATED_CONTACT");
}
}