Skip to content

Commit ce3a180

Browse files
committed
Fix two more instances of + signs added to links.
The first is image URLs rendered by markdown.go, the second is shortlinks rendered by html.go. However, with this commit I feel more certain that + was chosen for a reason, so it might be a good idea to track that down before this PR is accepted.
1 parent 01432d3 commit ce3a180

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

modules/markup/html.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -377,7 +377,7 @@ func RenderShortLinks(rawBytes []byte, urlPrefix string, noLink bool, isUncycloMark
377377
}
378378
absoluteLink := isLink([]byte(link))
379379
if !absoluteLink {
380-
link = strings.Replace(link, " ", "+", -1)
380+
link = strings.Replace(link, " ", "-", -1)
381381
}
382382
if image {
383383
if !absoluteLink {

modules/markup/markdown/markdown.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ func (r *Renderer) Image(out *bytes.Buffer, link []byte, title []byte, alt []byt
112112
} else {
113113
lnk := string(link)
114114
lnk = util.URLJoin(prefix, lnk)
115-
lnk = strings.Replace(lnk, " ", "+", -1)
115+
lnk = strings.Replace(lnk, " ", "-", -1)
116116
link = []byte(lnk)
117117
}
118118
}

0 commit comments

Comments
 (0)