refactor(#2787): replace deprecated
This commit is contained in:
@@ -173,7 +173,13 @@ local function open()
|
||||
|
||||
-- populate it
|
||||
vim.api.nvim_buf_set_lines(M.bufnr, 0, -1, false, lines)
|
||||
vim.api.nvim_buf_set_option(M.bufnr, "modifiable", false)
|
||||
|
||||
if vim.fn.has "nvim-0.10" == 1 then
|
||||
vim.api.nvim_set_option_value("modifiable", false, { buf = M.bufnr })
|
||||
else
|
||||
---@diagnostic disable-next-line: deprecated
|
||||
vim.api.nvim_buf_set_option(M.bufnr, "modifiable", false)
|
||||
end
|
||||
|
||||
-- highlight it
|
||||
for _, h in ipairs(hl) do
|
||||
|
||||
Reference in New Issue
Block a user