From 0a536ed5af3d9814522a5c437ed546229e5351b7 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Thu, 8 Aug 2019 20:13:10 -0400 Subject: [PATCH] Don't unnecessarily change ":verbose set scrollbind?" --- autoload/fugitive.vim | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index 6923c33..1ee3292 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -4647,8 +4647,10 @@ function! s:BlameCommand(line1, line2, range, count, bang, mods, reg, arg, args) let temp = s:Resolve(temp) let s:temp_files[s:cpath(temp)] = {'dir': s:Dir(), 'filetype': 'fugitiveblame', 'args': cmd} for winnr in range(winnr('$'),1,-1) - call setwinvar(winnr, '&scrollbind', 0) - if exists('+cursorbind') + if getwinvar(winnr, '&scrollbind') + call setwinvar(winnr, '&scrollbind', 0) + endif + if exists('+cursorbind') && getwinvar(winnr, '&cursorbind') call setwinvar(winnr, '&cursorbind', 0) endif if s:BlameBufnr(winbufnr(winnr)) > 0