mirror of
https://github.com/Luchexx/wacrm.git
synced 2026-11-02 17:29:45 +00:00
The INSERT into broadcasts in use-broadcast-sending.ts never set user_id, but broadcasts.user_id is NOT NULL + RLS-guarded. The INSERT rejected (23502 / 42501), the hook threw, handleSend caught with console.error only. UI showed nothing — the wizard stayed on Step 4 and the flow appeared dead. Fix: - Resolve session.user at the top of createAndSendBroadcast and include user_id on the broadcasts INSERT. - handleSend in /broadcasts/new now toasts the error via sonner so future failures are visible immediately instead of vanishing. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| app | ||
| components | ||
| hooks | ||
| lib | ||
| types | ||
| middleware.ts | ||