Update App.tsx
This commit is contained in:
2
App.tsx
2
App.tsx
@@ -162,7 +162,7 @@ const App: React.FC = () => {
|
|||||||
const shouldReopen = role === 'user' && t.status === TicketStatus.RESOLVED;
|
const shouldReopen = role === 'user' && t.status === TicketStatus.RESOLVED;
|
||||||
return {
|
return {
|
||||||
...t,
|
...t,
|
||||||
messages: [...t.messages, newMsg],
|
messages: [...(t.messages || []), newMsg], // FIX: Ensure array fallback
|
||||||
status: shouldReopen ? TicketStatus.OPEN : t.status
|
status: shouldReopen ? TicketStatus.OPEN : t.status
|
||||||
};
|
};
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user