Skip to content

Commit 1105468

Browse files
committed
Fix rendering cleanup of the paragraph surrounding a file-preview link
1 parent e8d9052 commit 1105468

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

modules/markup/html.go

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1312,12 +1312,10 @@ func filePreviewPatternProcessor(ctx *RenderContext, node *html.Node) {
13121312
Data: "</p>",
13131313
}, nextSibling)
13141314
node.Parent.InsertBefore(preview, nextSibling)
1315-
if after != "" {
1316-
node.Parent.InsertBefore(&html.Node{
1317-
Type: html.RawNode,
1318-
Data: "<p>" + after,
1319-
}, nextSibling)
1320-
}
1315+
node.Parent.InsertBefore(&html.Node{
1316+
Type: html.RawNode,
1317+
Data: "<p>" + after,
1318+
}, nextSibling)
13211319

13221320
node = node.NextSibling
13231321
}

0 commit comments

Comments
 (0)