Merge pull request #14472 from Davixk/fix/chat-loading-error

fix: Chat page fails to load on undefined message
This commit is contained in:
Tim Jaeryang Baek 2025-05-29 13:07:08 +04:00 committed by GitHub
commit f1507f2458
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1225,6 +1225,9 @@ export const createMessagesList = (history, messageId) => {
}
const message = history.messages[messageId];
if (message === undefined) {
return [];
}
if (message?.parentId) {
return [...createMessagesList(history, message.parentId), message];
} else {