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

@@ -157,7 +157,7 @@ custom_entries_view.open = function(self, offset, entries)
width = width + self.column_width.kind + (self.column_width.menu > 0 and 1 or 0)
width = width + self.column_width.menu + 1
local height = vim.api.nvim_get_option('pumheight')
local height = vim.api.nvim_get_option_value('pumheight', {})
height = height ~= 0 and height or #self.entries
height = math.min(height, #self.entries)