mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-06-22 06:41:46 +00:00
fix(mcp): safeBroadcast now calls broadcast correctly (was recursive call bug)
This commit is contained in:
@@ -6,9 +6,9 @@ import { isDemoUser } from '../services/authService';
|
|||||||
|
|
||||||
function safeBroadcast(tripId: number, event: string, payload: Record<string, unknown>): void {
|
function safeBroadcast(tripId: number, event: string, payload: Record<string, unknown>): void {
|
||||||
try {
|
try {
|
||||||
safeBroadcast(tripId, event, payload);
|
broadcast(tripId, event, payload);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.error(`[MCP] broadcast failed for ${event}:`, err);
|
console.error(`[MCP] broadcast failed for ${event}:`, err?.message ?? err);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
import {
|
import {
|
||||||
|
|||||||
Reference in New Issue
Block a user