From ccd419bb0f452da6835b4b603ce2afb02fb46fe0 Mon Sep 17 00:00:00 2001 From: Bailey Ling Date: Sun, 22 Sep 2013 17:43:14 -0400 Subject: [PATCH] fix 7.2 incompatibility. --- autoload/airline/extensions/default.vim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/autoload/airline/extensions/default.vim b/autoload/airline/extensions/default.vim index 1fe889a..5d21996 100644 --- a/autoload/airline/extensions/default.vim +++ b/autoload/airline/extensions/default.vim @@ -11,7 +11,6 @@ let s:layout = get(g:, 'airline#extensions#default#layout', [ \ [ 'a', 'b', 'c' ], \ [ 'x', 'y', 'z', 'warning' ] \ ]) -let s:spc = g:airline_symbols.space function! s:get_section(winnr, key, ...) if has_key(s:section_truncate_width, a:key) @@ -19,8 +18,9 @@ function! s:get_section(winnr, key, ...) return '' endif endif + let spc = g:airline_symbols.space let text = airline#util#getwinvar(a:winnr, 'airline_section_'.a:key, g:airline_section_{a:key}) - let [prefix, suffix] = [get(a:000, 0, '%('.s:spc), get(a:000, 1, s:spc.'%)')] + let [prefix, suffix] = [get(a:000, 0, '%('.spc), get(a:000, 1, spc.'%)')] return empty(text) ? '' : prefix.text.suffix endfunction