fix(whatsapp-cache): improve error logging in save function

Updated the error handling in the saveOnWhatsappCache function to log the error message separately, improving clarity on issues encountered during item processing.
This commit is contained in:
Davidson Gomes 2025-11-07 14:41:31 -03:00
parent 139ad9b3cb
commit f4043a9141

View File

@ -170,7 +170,8 @@ export async function saveOnWhatsappCache(data: ISaveOnWhatsappCacheParams[]) {
}
} catch (e) {
// Loga o erro mas não para a execução dos outros promises
logger.error(`[saveOnWhatsappCache] Error processing item for ${item.remoteJid}: `, e);
logger.error(`[saveOnWhatsappCache] Error processing item for ${item.remoteJid}: `);
logger.error(e);
}
});