From 2e19b57667138eeb51bea5944f75792f255383e6 Mon Sep 17 00:00:00 2001 From: Du Hoang Date: Wed, 28 Feb 2024 18:31:25 +0700 Subject: [PATCH] fix: check mentions array --- src/modules/simple-mover/transfers/CodaExporter.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/simple-mover/transfers/CodaExporter.ts b/src/modules/simple-mover/transfers/CodaExporter.ts index 43a0e29..6fa8129 100644 --- a/src/modules/simple-mover/transfers/CodaExporter.ts +++ b/src/modules/simple-mover/transfers/CodaExporter.ts @@ -123,7 +123,7 @@ export class CodaExporter implements IExporter { if (!this.outlineApis) throw Error('No outline token') const mentions = markdownContent.match(CODA_MENTION_REPLACEMENT_REGEX) - if (!mentions?.length) return + if (!mentions) return const emailsSet = new Set(mentions.map(mention => { const email = mention.match(/(?<=mailto:)[^)]+/)