Skip to content

Commit c66fe25

Browse files
committed
ignore command and mcp asks with no text
1 parent efdc3a8 commit c66fe25

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

webview-ui/src/components/chat/ChatView.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ const ChatView = ({ isHidden, showAnnouncement, hideAnnouncement, showHistoryVie
139139
setSecondaryButtonText("Reject")
140140
break
141141
case "command":
142-
if (!isAutoApproved(lastMessage)) {
142+
if (lastMessage.text && !isAutoApproved(lastMessage)) {
143143
playSound("notification")
144144
}
145145
setTextAreaDisabled(isPartial)
@@ -156,7 +156,7 @@ const ChatView = ({ isHidden, showAnnouncement, hideAnnouncement, showHistoryVie
156156
setSecondaryButtonText(undefined)
157157
break
158158
case "use_mcp_server":
159-
if (!isAutoApproved(lastMessage)) {
159+
if (lastMessage.text && !isAutoApproved(lastMessage)) {
160160
playSound("notification")
161161
}
162162
setTextAreaDisabled(isPartial)

0 commit comments

Comments
 (0)