mirror of
https://github.com/amix/vimrc
synced 2025-06-23 06:35:01 +08:00
Updated plugins
This commit is contained in:
@ -84,11 +84,14 @@ function! s:CheckForBadConfig(buffer, lines) abort
|
||||
endfunction
|
||||
|
||||
function! s:parseJSON(buffer, lines) abort
|
||||
try
|
||||
let l:parsed = json_decode(a:lines[-1])
|
||||
catch
|
||||
return []
|
||||
endtry
|
||||
let l:parsed = []
|
||||
|
||||
for l:line in a:lines
|
||||
try
|
||||
let l:parsed = extend(l:parsed, json_decode(l:line))
|
||||
catch
|
||||
endtry
|
||||
endfor
|
||||
|
||||
if type(l:parsed) != v:t_list || empty(l:parsed)
|
||||
return []
|
||||
|
Reference in New Issue
Block a user