url fix
This commit is contained in:
parent
6f76d2efd6
commit
b96d4c5452
1 changed files with 1 additions and 1 deletions
2
tree.go
2
tree.go
|
@ -258,7 +258,7 @@ func fixFormat(dir string, attachmentRegistry map[string]string) error {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
aPath := path.Clean(fmt.Sprintf("%s/%s", path.Dir(fullPath), string(match[2][:])))
|
aPath := path.Clean(fmt.Sprintf("%s/%s", path.Dir(fullPath), string(match[2][:])))
|
||||||
if _, ok := attachmentRegistry[aPath]; ok {
|
if _, ok := attachmentRegistry[aPath]; ok {
|
||||||
link := fmt.Sprintf("(%s)[%s]", match[1], attachmentRegistry[aPath])
|
link := fmt.Sprintf("![%s](%s)", match[1], attachmentRegistry[aPath])
|
||||||
data = bytes.Replace(data, match[0], []byte(link), 1)
|
data = bytes.Replace(data, match[0], []byte(link), 1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue