diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2023-11-24 13:43:34 -0400 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2023-11-24 14:18:27 -0400 |
commit | 803a17296249e1521089451c9d077cc524b4acf5 (patch) | |
tree | 0802f7a53287fb68c6320596f56a2a88c2881b63 /src/util | |
parent | 153a9f927073d69773af9bf30a53e94cac91d5a9 (diff) |
external-links: minor code fixes
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/external-links.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/util/external-links.js b/src/util/external-links.js index 07a83bc1..dee65cc5 100644 --- a/src/util/external-links.js +++ b/src/util/external-links.js @@ -380,7 +380,7 @@ export function extractPartFromExternalLink(url, extract) { let prefix = ''; if (extract instanceof RegExp) { - regexen.push(descriptor.handle); + regexen.push(extract); tests.push(url); } else { for (const [key, value] of Object.entries(extract)) { @@ -403,6 +403,7 @@ export function extractPartFromExternalLink(url, extract) { case 'query': tests.push(query.slice(1)); + break; default: tests.push(''); |