Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.
Mirrored from https://github.com/Camo67/composio.git
Synced Nov 22, 07:00 UTC
fix(cli): use unbind_all for Pusher channel cleanup
unbind() with no arguments does not remove all listeners in Pusher's API. Use unbind_all() to properly clear trigger_to_client and chunked-trigger_to_client handlers before unsubscribe/disconnect.
jkomyno committed
Feb 24, 2026 at 13:41 UTC
b3f7864985c088bb7cd9bbb500df0dd0da107b33
1 file changed
+2
-1
ts/packages/cli/src/services/triggers-realtime.ts
+2
-1
@@ -22,6 +22,7 @@ type PusherChannel = {
22
bind: (event: string, callback: (data: unknown) => void) => void;
23
bind_global?: (callback: (eventName: string, data: unknown) => void) => void;
24
unbind?: (event?: string, callback?: (data: unknown) => void) => void;
25
+ unbind_all?: () => void;
26
};
27
28
type PusherClient = {
@@ -228,7 +229,7 @@ export class TriggersRealtime extends Effect.Service<TriggersRealtime>()(
229
return {
230
shutdown: async () => {
231
clearInterval(cleanupInterval);
231
- channel.unbind?.();
232
+ channel.unbind_all?.();
233
pusher.unsubscribe(channelName);
234
pusher.disconnect();
235
},