Skip to content

Commit ebca56e

Browse files
committed
fix: use channel method for stopping
1 parent f8e2364 commit ebca56e

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@
145145
"emoji-mart": "^5.4.0",
146146
"react": "^18.0.0 || ^17.0.0 || ^16.8.0",
147147
"react-dom": "^18.0.0 || ^17.0.0 || ^16.8.0",
148-
"stream-chat": "^8.45.0"
148+
"stream-chat": "^8.46.0"
149149
},
150150
"peerDependenciesMeta": {
151151
"@breezystack/lamejs": {

src/components/MessageInput/MessageInputFlat.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,7 @@ export const MessageInputFlat = <
8181

8282
const { aiState } = useAIState(channel);
8383

84-
const stopGenerating = useCallback(() => channel?.sendEvent({ type: 'ai_indicator.stop' }), [
85-
channel,
86-
]);
84+
const stopGenerating = useCallback(() => channel?.stopAIResponse(), [channel]);
8785

8886
const [
8987
showRecordingPermissionDeniedNotification,

0 commit comments

Comments
 (0)