Skip to content

Commit 9c68513

Browse files
committed
Preserve whitespace in b:commentary_format
Closes #33.
1 parent 401dbd8 commit 9c68513

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

plugin/commentary.vim

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,8 @@ endif
99
let g:loaded_commentary = 1
1010

1111
function! s:surroundings() abort
12-
return split(substitute(substitute(
13-
\ get(b:, 'commentary_format', &commentstring)
14-
\ ,'\S\zs%s',' %s','') ,'%s\ze\S', '%s ', ''), '%s', 1)
12+
return split(get(b:, 'commentary_format', substitute(substitute(
13+
\ &commentstring, '\S\zs%s',' %s','') ,'%s\ze\S', '%s ', '')), '%s', 1)
1514
endfunction
1615

1716
function! s:go(type,...) abort

0 commit comments

Comments
 (0)