mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
remove extra line, remove () in error
This commit is contained in:
parent
e65d0e53b1
commit
2d06538b5e
@ -256,14 +256,13 @@ vim.fn = setmetatable({}, {
|
|||||||
local _fn
|
local _fn
|
||||||
if vim.api[key] ~= nil then
|
if vim.api[key] ~= nil then
|
||||||
_fn = function(...)
|
_fn = function(...)
|
||||||
error(string.format("Tried to call API function with vim.fn: use vim.api.%s() instead", key))
|
error(string.format("Tried to call API function with vim.fn: use vim.api.%s instead", key))
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
_fn = function(...)
|
_fn = function(...)
|
||||||
return vim.call(key, ...)
|
return vim.call(key, ...)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
t[key] = _fn
|
t[key] = _fn
|
||||||
return _fn
|
return _fn
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user