autoload: use airline#util#warning instead of echo

This commit is contained in:
Christian Brabandt 2018-11-13 21:21:55 +01:00
parent 464633baad
commit c850f485ad
No known key found for this signature in database
GPG Key ID: F3F92DA383FDDE09

View File

@ -19,9 +19,7 @@ endfunction
function! airline#add_statusline_funcref(function) function! airline#add_statusline_funcref(function)
if index(g:airline_statusline_funcrefs, a:function) >= 0 if index(g:airline_statusline_funcrefs, a:function) >= 0
echohl WarningMsg call airline#util#warning('The airline statusline funcref %s has already been added.', string(a:function))
echo 'The airline statusline funcref '.string(a:function).' has already been added.'
echohl NONE
return return
endif endif
call add(g:airline_statusline_funcrefs, a:function) call add(g:airline_statusline_funcrefs, a:function)