Do the right thing for g:markdown_folding == 0

This commit is contained in:
Tim Pope
2021-03-11 13:28:08 -05:00
parent 65cb65a31a
commit 855b8915e0

View File

@@ -72,7 +72,7 @@ function! MarkdownFoldText() abort
return hash_indent.' '.title.' '.linecount
endfunction
if has("folding") && exists("g:markdown_folding")
if has("folding") && get(g:, "markdown_folding", 0)
setlocal foldexpr=MarkdownFold()
setlocal foldmethod=expr
setlocal foldtext=MarkdownFoldText()