From 43f69e068c24ed8eb8cd00085c04a17360c26ab7 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Sun, 8 Jul 2018 00:45:18 +1200 Subject: Give cutoff point a sensible starting value This was causing blank buffers to mis-report the number of deleted lines. You can't delete line 1 (well, not really). --- 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 b332034..2714f36 100644 --- a/plugin/strip_trailing_whitespace.vim +++ b/plugin/strip_trailing_whitespace.vim @@ -17,7 +17,7 @@ let g:loaded_strip_trailing_whitespace = 1 function! s:StripTrailingWhitespace() " Line number of last line that had non-whitespace characters on it - let l:cutoff = 0 + let l:cutoff = 1 " Tracking lines trimmed between non-whitespace lines and then totalling let l:trimmed_buffer = 0 -- cgit v1.2.3