mirror of
https://github.com/vim-airline/vim-airline.git
synced 2026-01-21 02:22:04 +08:00
netrw: do not error out when g:netrw_sort_by is not defined
This commit is contained in:
@@ -31,5 +31,5 @@ endfunction
|
||||
|
||||
function! airline#extensions#netrw#sortstring()
|
||||
let order = (get(g:, 'netrw_sort_direction', 'n') =~ 'n') ? '+' : '-'
|
||||
return g:netrw_sort_by . (g:airline_symbols.space) . '[' . order . ']'
|
||||
return get(g:, 'netrw_sort_by', '') . (g:airline_symbols.space) . '[' . order . ']'
|
||||
endfunction
|
||||
|
||||
Reference in New Issue
Block a user