use nvim_get_option_value instead of nvim{,_buf,_win}_get_option

This commit is contained in:
hrsh7th
2024-05-17 22:56:28 +09:00
parent abacd4cb7f
commit 5260e5e8ec
5 changed files with 5 additions and 5 deletions

View File

@@ -9,7 +9,7 @@ return function()
local config = {
enabled = function()
local disabled = false
disabled = disabled or (vim.api.nvim_buf_get_option(0, 'buftype') == 'prompt')
disabled = disabled or (vim.api.nvim_get_option_value('buftype', { buf = 0 }) == 'prompt')
disabled = disabled or (vim.fn.reg_recording() ~= '')
disabled = disabled or (vim.fn.reg_executing() ~= '')
return not disabled