diff --git a/src/ChatWindow/Message.vue b/src/ChatWindow/Message.vue index ff546a51..de7cd976 100644 --- a/src/ChatWindow/Message.vue +++ b/src/ChatWindow/Message.vue @@ -412,7 +412,7 @@ export default { if (!file) return const imageTypes = ['png', 'jpg', 'jpeg', 'svg'] const { type } = file - return imageTypes.some(t => type.includes(t)) + return imageTypes.some(t => type.toLowerCase().includes(t)) }, checkImgLoad() { if (!this.checkImageFile()) return diff --git a/src/ChatWindow/Room.vue b/src/ChatWindow/Room.vue index d8b97e7b..a150e947 100644 --- a/src/ChatWindow/Room.vue +++ b/src/ChatWindow/Room.vue @@ -587,7 +587,7 @@ export default { if (!file) return const imageTypes = ['png', 'jpg', 'jpeg', 'svg'] const { type } = file - return imageTypes.some(t => type.includes(t)) + return imageTypes.some(t => type.toLowerCase().includes(t)) }, openFile({ message, action }) { this.$emit('openFile', { message, action })