Skip to content

Commit

Permalink
fix: remove vim.validate
Browse files Browse the repository at this point in the history
Closes #24
  • Loading branch information
rcarriga committed Jan 20, 2025
1 parent 2f6137d commit 21f5324
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions lua/nio/tasks.lua
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,6 @@ end
---@param argc? number
---@return function
function nio.tasks.create(func, argc)
vim.validate({
func = { func, "function" },
argc = { argc, "number", true },
})
argc = argc or 0
return function(...)
if current_non_main_co() then
Expand All @@ -180,7 +176,6 @@ end
---@nodoc
function nio.tasks.wrap(func, argc, opts)
opts = vim.tbl_extend("keep", opts or {}, { strict = true })
vim.validate({ func = { func, "function" }, argc = { argc, "number" } })
local protected = function(...)
local args = { ... }
local cb = args[argc]
Expand Down

0 comments on commit 21f5324

Please sign in to comment.