From 51f054dcfc2fb6c57489396919f4d1a042d63698 Mon Sep 17 00:00:00 2001 From: derpystuff <3515180-derpystuff@users.noreply.gitlab.com> Date: Thu, 26 May 2022 18:42:35 +0200 Subject: [PATCH] [fix] attachment helper for videos --- labscore/utils/attachment.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/labscore/utils/attachment.js b/labscore/utils/attachment.js index 0183367..79714fc 100644 --- a/labscore/utils/attachment.js +++ b/labscore/utils/attachment.js @@ -76,7 +76,7 @@ async function getRecentVideo(context, limit) { ) { attachments.push(message.embeds.toArray()[0].video) } else if (message.attachments.first() && - message.attachments.first().contentType.includes("video")){ + message.attachments.first().contentType?.includes("video")){ attachments.push(message.attachments.first()) } }