Skip to content

Conversation

@RaFaeL-Cunha
Copy link

📋 Description

Este PR resolve múltiplos bugs e melhora a lógica de tratamento de mensagens, especialmente eventos de edição e deleção (EDIT/DELETE):

Tratamento de Mensagem Apagada: Corrige o erro onde mensagens apagadas (REVOKE) exibiam undefined na integração Chatwoot. Agora, exibe Mensagem apagada pelo remetente.

Tratamento de Edição de Caption: Implementa lógica para processar corretamente a edição de captions (legendas de imagens/arquivos), que antes só tratava edição de mensagens de texto.

Deduplicação Reforçada: Implementa mecanismos de anti-duplicação mais robustos para eventos de edição e deleção.

Refactoring LID (onWhatsappCache.ts): Ajusta a lógica de persistência do campo lid (Local ID) para garantir consistência durante o upsert.

🔗 Related Issue

Closes #(issue_number)

🧪 Type of Change

[x] 🐛 Bug fix (non-breaking change which fixes an issue)

[ ] ✨ New feature (non-breaking change which adds functionality)

[ ] 💥 Breaking change (fix or feature that would cause existing functionality to not work as expected)

[ ] 📚 Documentation update

[x] 🔧 Refactoring (no functional changes)

[ ] ⚡ Performance improvement

[ ] 🧹 Code cleanup

[ ] 🔒 Security fix

🧪 Testing

[x] Manual testing completed

[x] Functionality verified in development environment

[x] No breaking changes introduced

[ ] Tested with different connection types (if applicable)

📸 Screenshots (if applicable)

N/A (As alterações são primariamente de lógica de backend e tratamento de eventos).

✅ Checklist

[x] My code follows the project's style guidelines

[x] I have performed a self-review of my code

[x] I have commented my code, particularly in hard-to-understand areas

[ ] I have made corresponding changes to the documentation

[x] My changes generate no new warnings

[x] I have manually tested my changes thoroughly

[x] I have verified the changes work with different scenarios

[ ] Any dependent changes have been merged and published

📝 Additional Notes

O código foi re-enviado a partir de uma base limpa para resolver problemas de histórico de fork. O diff contém o bug fix de deleção/edição e o refactoring do LID.

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @RaFaeL-Cunha, your pull request is larger than the review limit of 150000 diff characters

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant