Skip to content

Commit d0997d0

Browse files
committed
Fix permission denied toast errors on WS updates for restricted agents
Ref #252
1 parent 1ab7825 commit d0997d0

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

frontend/src/stores/conversation.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -603,6 +603,12 @@ export const useConversationStore = defineStore('conversation', () => {
603603
* @param {object} message - Message object with conversation_uuid field
604604
*/
605605
async function updateConversationMessage (message) {
606+
// Skip if the message's conversation UUID is not in the list.
607+
if (!conversationUUIDExists(message.conversation_uuid) &&
608+
conversation.data?.uuid !== message.conversation_uuid) {
609+
return
610+
}
611+
606612
// Message does not exist in cache? fetch from server and update.
607613
if (!messages.data.hasMessage(message.conversation_uuid, message.uuid)) {
608614
fetchParticipants(message.conversation_uuid)

0 commit comments

Comments
 (0)