From 23cbd014bbe10589cbccabd5b25dae3da655cb71 Mon Sep 17 00:00:00 2001 From: tienifr Date: Tue, 20 Feb 2024 14:59:24 +0700 Subject: [PATCH] fix: app crashes when open default workspace avatar --- src/components/Attachments/AttachmentView/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/Attachments/AttachmentView/index.js b/src/components/Attachments/AttachmentView/index.js index d02957aa8137..6da7be841537 100755 --- a/src/components/Attachments/AttachmentView/index.js +++ b/src/components/Attachments/AttachmentView/index.js @@ -100,7 +100,7 @@ function AttachmentView({ const styles = useThemeStyles(); const StyleUtils = useStyleUtils(); const [loadComplete, setLoadComplete] = useState(false); - const isVideo = Str.isVideo(source); + const isVideo = typeof source === 'string' && Str.isVideo(source); useEffect(() => { if (!isFocused) {