From b299f9bc42521191903bc2b6226933d319f6c593 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Sun, 8 Jul 2018 00:56:10 +1200 Subject: Fix another edge case --- plugin/strip_trailing_whitespace.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plugin') diff --git a/plugin/strip_trailing_whitespace.vim b/plugin/strip_trailing_whitespace.vim index 2714f36..f3e01c0 100644 --- a/plugin/strip_trailing_whitespace.vim +++ b/plugin/strip_trailing_whitespace.vim @@ -42,7 +42,7 @@ function! s:StripTrailingWhitespace() " If this line has any non-whitespace characters on it, update our cutoff " point using its index, and push the trimmed lines we've counted since " the last non-whitespace line onto the trimmed total - if l:line =~# '\S' + if l:line =~# '\S' || l:last == 1 let l:cutoff = l:li let l:trimmed = l:trimmed + l:trimmed_buffer let l:trimmed_buffer = 0 -- cgit v1.2.3