diff --git a/packages/server/src/chat/service.ts b/packages/server/src/chat/service.ts index 60830e0dd..67cc1c238 100644 --- a/packages/server/src/chat/service.ts +++ b/packages/server/src/chat/service.ts @@ -90,6 +90,10 @@ export class ChatService extends Service { ) { // TODO: we don't need to get the config here. Just getting the conduitId would be way better const conduit = await this.conduits.getByProviderAndChannel(client!.providerId, tunnel!.channelId) + if (!conduit) { + continue + } + const instance = await this.instances.get(conduit!.id) await instance.sendToEndpoint(endpoint, payload) }