fix: Cannot read properties of undefined (reading 'filter') (#7522)

This commit is contained in:
Pranav Raj S 2023-07-13 15:56:28 -07:00 committed by GitHub
parent 66751b71dd
commit 9de2edd300
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -49,8 +49,7 @@ const getters = {
},
getSelectedChatAttachments: (_state, _getters) => {
const selectedChat = _getters.getSelectedChat;
const { attachments } = selectedChat;
return attachments;
return selectedChat.attachments || [];
},
getLastEmailInSelectedChat: (stage, _getters) => {
const selectedChat = _getters.getSelectedChat;