Skip to content

Commit

Permalink
Update useMessages.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
zAlweNy26 committed Mar 29, 2024
1 parent 0c5b1d7 commit 70e0cd9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/stores/useMessages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ export const useMessages = defineStore('messages', () => {
if (currentState.generating) {
const index = currentState.messages.findIndex(m => m.id === currentState.generating)
currentState.messages[index].text = content
if (currentState.messages[index].sender === 'bot') currentState.messages[index].why = why
;(currentState.messages[index] as BotMessage).why = why
currentState.generating = undefined
} else {
addMessage({
Expand Down

0 comments on commit 70e0cd9

Please sign in to comment.