diff --git a/plugin/surround.vim b/plugin/surround.vim index 71da7a1..8eee147 100644 --- a/plugin/surround.vim +++ b/plugin/surround.vim @@ -178,8 +178,10 @@ function! s:wrap(string,char,type,...) if dounmapb silent! cunmap > endif + let s:tag = tag if tag != "" let tag = substitute(tag,'>*$','','') + let s:tag = tag . '>' let before = '<'.tag.'>' if tag =~ '/$' let after = ''