Skip to content

Commit 32f3c0c

Browse files
fix bug (#381)
1 parent 4036d8a commit 32f3c0c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

wiki-tools/brokenlinks.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ searchfile() {
4747
# Replace the old link with the new one.
4848
# Parentheses are placed around both the old link and new one in order to ensure we replace the link,
4949
# and not some other place in the file that happens to use the same words.
50-
REPLACE=$(escape '('$link')')
50+
REPLACE=$(escape '('"$link"')')
5151
REPLACEWITH=$(escapeReplace "$NEWLINK")
5252
sed -i "s/$REPLACE/\($REPLACEWITH\)/" "$1"
5353
fi
@@ -97,7 +97,7 @@ searchfile() {
9797
# Replace the old link with the new one.
9898
# Parentheses are placed around both the old link and new one in order to ensure we replace the link,
9999
# and not some other place in the file that happens to use the same words.
100-
REPLACE=$(escape '('$link')')
100+
REPLACE=$(escape '('"$link"')')
101101
REPLACEWITH=$(escapeReplace "$(basename "$FILE" .md)")
102102
sed -i "s/$REPLACE/\($REPLACEWITH\)/" "$1"
103103
continue

0 commit comments

Comments
 (0)