Fix for slowness due to folds (#143)

This commit is contained in:
David Palma
2019-07-24 22:59:55 +02:00
committed by Tim Pope
parent 57c58269a2
commit fd3f4831be

View File

@@ -23,9 +23,8 @@ function! MarkdownFold()
let line = getline(v:lnum)
" Regular headers
let depth = match(line, '\(^#\+\)\@<=\( .*$\)\@=')
if depth > 0
return ">" . depth
if line =~# '^#\+ '
return ">" . match(line, ' ')
endif
" Setext style headings