diff --git a/apps/ssb/tf-compose.js b/apps/ssb/tf-compose.js index fbeab91a..26f589c2 100644 --- a/apps/ssb/tf-compose.js +++ b/apps/ssb/tf-compose.js @@ -37,6 +37,11 @@ class TfComposeElement extends LitElement { for (let match of text.matchAll(/\[([^\[]+)]\(([@&%][^\)]+)/g)) { let name = match[1]; let link = match[2]; + if ((link.startsWith('&') && link.length != 52) || + (link.startsWith('@') && link.length != 53) || + (link.startsWith('%') && link.length != 52)) { + continue; + } let balance = 0; let bracket_end = match.index + match[1].length + '[]'.length - 1; for (let i = bracket_end; i >= 0; i--) {