mirror of
https://github.com/hrsh7th/cmp-buffer
synced 2025-05-06 10:09:52 +00:00
don't use deprecated functions
This commit is contained in:
parent
3022dbc916
commit
51f42e6ef6
@ -31,13 +31,11 @@ end
|
||||
---@return cmp_buffer.Options
|
||||
source._validate_options = function(_, params)
|
||||
local opts = vim.tbl_deep_extend('keep', params.option, defaults)
|
||||
vim.validate({
|
||||
keyword_length = { opts.keyword_length, 'number' },
|
||||
keyword_pattern = { opts.keyword_pattern, 'string' },
|
||||
get_bufnrs = { opts.get_bufnrs, 'function' },
|
||||
indexing_batch_size = { opts.indexing_batch_size, 'number' },
|
||||
indexing_interval = { opts.indexing_interval, 'number' },
|
||||
})
|
||||
vim.validate('keyword_length', opts.keyword_length, 'number')
|
||||
vim.validate('keyword_pattern', opts.keyword_pattern, 'string')
|
||||
vim.validate('get_bufnrs', opts.get_bufnrs, 'function')
|
||||
vim.validate('indexing_batch_size', opts.indexing_batch_size, 'number')
|
||||
vim.validate('indexing_interval', opts.indexing_interval, 'number')
|
||||
return opts
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user