diff options
author | Anna Dabrowska <dabrowska@cosmocode.de> | 2024-10-21 12:55:34 +0200 |
---|---|---|
committer | Anna Dabrowska <dabrowska@cosmocode.de> | 2024-10-21 12:55:34 +0200 |
commit | 518edfb102c269ea2c3fcd1c593f1925d8e18327 (patch) | |
tree | 6480ec07b03c69767778ee47c01396aaada0feb9 /lib/scripts/linkwiz.js | |
parent | 9085b15ba88b1e1dc68974a8c494e04e74928754 (diff) | |
download | dokuwiki-518edfb102c269ea2c3fcd1c593f1925d8e18327.tar.gz dokuwiki-518edfb102c269ea2c3fcd1c593f1925d8e18327.zip |
LinkWizard: fix multilevel parents in references
Diffstat (limited to 'lib/scripts/linkwiz.js')
-rw-r--r-- | lib/scripts/linkwiz.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/scripts/linkwiz.js b/lib/scripts/linkwiz.js index d34ef3899..cd0c1d7f0 100644 --- a/lib/scripts/linkwiz.js +++ b/lib/scripts/linkwiz.js @@ -398,7 +398,7 @@ class LinkWizard { // namespaces are irrelevant } else if (commonPrefixLength < sourceNs.length) { // add .. for each missing namespace from common to the target - relativeID.push('..'.repeat(sourceNs.length - commonPrefixLength)); + relativeID.push(...Array(sourceNs.length - commonPrefixLength).fill('..')); } else { // target is below common prefix, add . relativeID.push('.'); |