From 9bba261e53a0082d27fd5b88f0446a09313a76e7 Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Wed, 19 Aug 2015 17:34:01 +0900 Subject: [PATCH] Cleanup --- vimdoc.go | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/vimdoc.go b/vimdoc.go index 2662036..748cfe3 100644 --- a/vimdoc.go +++ b/vimdoc.go @@ -106,15 +106,17 @@ func (v *vimDoc) buildHelpTag(text []byte) []byte { func (v *vimDoc) buildChapters(h *heading) []byte { index := -1 - for i, curr := range v.headings { - if curr == h { - index = i - break + { + for i, curr := range v.headings { + if curr == h { + index = i + break + } } - } - if index < 0 { - log.Fatal("heading not found") + if index < 0 { + log.Fatal("heading not found") + } } var chapters []int