fix :LspDocumentDiagnostics

This commit is contained in:
prabirshrestha
2020-01-01 18:12:26 -08:00
parent b02345d223
commit 44e0823d55

View File

@@ -121,7 +121,7 @@ function! lsp#ui#vim#utils#diagnostics_to_loc_list(result) abort
let l:text .= l:item['code'] . ':'
endif
let l:text .= l:item['message']
let [l:line, l:col] = lsp#utils#position#_lsp_to_vim(l:path, l:item['range'])
let [l:line, l:col] = lsp#utils#position#_lsp_to_vim(l:path, l:item['range']['start'])
call add(l:list, {
\ 'filename': l:path,
\ 'lnum': l:line,
@@ -131,6 +131,7 @@ function! lsp#ui#vim#utils#diagnostics_to_loc_list(result) abort
endfor
endif
return l:list
endfunction