mirror of
https://github.com/vim-airline/vim-airline.git
synced 2024-11-22 15:59:23 +08:00
coc-extension: remove dead code
vim-airline does not use actually use the `g:coc_stl_format` variable and it also doesn't seem to be used by coc itself. So let's just remove this code. closes #2437
This commit is contained in:
parent
0a7e1bc475
commit
26f922753a
|
@ -21,19 +21,11 @@ function! airline#extensions#coc#get(type) abort
|
|||
endif
|
||||
let _backup = get(g:, 'coc_stl_format', '')
|
||||
let is_err = (a:type is# 'error')
|
||||
if is_err
|
||||
let g:coc_stl_format = get(g:, 'airline#extensions#coc#stl_format_err', '%E{[%e(#%fe)]}')
|
||||
else
|
||||
let g:coc_stl_format = get(g:, 'airline#extensions#coc#stl_format_warn', '%W{[%w(#%fw)]}')
|
||||
endif
|
||||
let info = get(b:, 'coc_diagnostic_info', {})
|
||||
if empty(info) | return '' | endif
|
||||
|
||||
|
||||
let cnt = get(info, a:type, 0)
|
||||
if !empty(_backup)
|
||||
let g:coc_stl_format = _backup
|
||||
endif
|
||||
|
||||
if empty(cnt)
|
||||
return ''
|
||||
|
|
|
@ -636,12 +636,6 @@ coc <https://github.com/neoclide/coc.nvim>
|
|||
* change warning symbol: >
|
||||
let airline#extensions#coc#warning_symbol = 'W:'
|
||||
<
|
||||
* change error format: >
|
||||
let airline#extensions#coc#stl_format_err = '%E{[%e(#%fe)]}'
|
||||
<
|
||||
* change warning format: >
|
||||
let airline#extensions#coc#stl_format_warn = '%W{[%w(#%fw)]}'
|
||||
|
||||
------------------------------------- *airline-commandt*
|
||||
command-t <https://github.com/wincent/command-t>
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user