Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

fix: use regex.exec instead of str.match

thecodrr62e692949f06
diff --git a/packages/core/content-types/tiny.js b/packages/core/content-types/tiny.js
index 7ffc2f037..06e6c48a4 100644
--- a/packages/core/content-types/tiny.js
+++ b/packages/core/content-types/tiny.js
@@ -118,7 +118,7 @@ class Tiny {
break;
}
case "span": {
- const matches = node.match(HASH_REGEX);
+ const matches = HASH_REGEX.exec(node);
if (!matches) continue;
const [_match, hash] = matches;
attachments.push({ hash });