Skip to content

Commit 3f6e23f

Browse files
authored
Use prop_remove before adding virtual text (#1411)
1 parent 2cb7ef5 commit 3f6e23f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

autoload/lsp/internal/diagnostics/virtual_text.vim

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,8 @@ function! s:place_virtual_text(server, diagnostics_response, bufnr) abort
176176
" anymore due to async processing, just skip such diagnostics
177177
if l:line <= getbufinfo(a:bufnr)[0].linecount
178178
let l:type = 'vim_lsp_' . l:name . '_virtual_text'
179-
call prop_add(l:line, 0, {'type': l:type, 'text': l:text, 'text_padding_left': 1, 'bufnr': a:bufnr})
179+
call prop_remove({'all': v:true, 'type': l:type, 'bufnr': a:bufnr}, l:line)
180+
call prop_add(l:line, 0, {'type': l:type, 'text': l:text, 'text_padding_left': 1, 'bufnr': a:bufnr, 'text_align': 'below', 'text_wrap': 'wrap'})
180181
endif
181182
endif
182183
endfor

0 commit comments

Comments
 (0)