fix(paradizweb): confirm booking lead dispatch after contact capture

This commit is contained in:
OpenClaw Assistant
2026-03-03 00:11:40 +03:00
parent a3d2beb54a
commit 7f4b7c1eb1

View File

@@ -231,9 +231,15 @@ const server = http.createServer(async (req, res) => {
}
if (clientId && pendingBookingByClient.get(clientId) && hasContactInfo(question) && !bookingLeadSentByClient.get(clientId)) {
await sendTelegramBookingLead(question).catch(() => {});
const sent = await sendTelegramBookingLead(question).catch(() => false);
pendingBookingByClient.delete(clientId);
bookingLeadSentByClient.set(clientId, true);
return json(res, 200, {
ok: true,
answer: sent
? 'Спасибо! Передала заявку на бронь менеджеру, он свяжется с вами.'
: 'Спасибо! Контакт записала. Есть техническая задержка с уведомлением менеджера, но заявка сохранена.'
});
}
if (isExternalActionRequest(question)) {