block.go: set fenceLength (#505)
Robert Lowry bobertlo@gmail.com
Sun, 20 Jan 2019 12:09:27 -0600
1 files changed,
2 insertions(+),
0 deletions(-)
jump to
M
block.go
→
block.go
@@ -673,6 +673,7 @@ beg, marker := isFenceLine(data, &info, "")
if beg == 0 || beg >= len(data) { return 0 } + fenceLength := beg - 1 var work bytes.Buffer work.Write([]byte(info))@@ -706,6 +707,7 @@
if doRender { block := p.addBlock(CodeBlock, work.Bytes()) // TODO: get rid of temp buffer block.IsFenced = true + block.FenceLength = fenceLength finalizeCodeBlock(block) }