There's at least five different copy/pasted instances of a setInterval function in the scenarios for TCP networking... like this:
-- Creating a simple setInterval wrapper
local uv = require("uv")
local function setInterval(interval, callback)
local timer = uv.new_timer()
timer:start(interval, interval, function()
callback()
end)
return timer
end
They should likely be moved to a C_Timer API namespace, and properly tested. Or maybe just relying on libuv tests is enough?
There's at least five different copy/pasted instances of a
setInterval
function in the scenarios for TCP networking... like this:They should likely be moved to a
C_Timer
API namespace, and properly tested. Or maybe just relying on libuv tests is enough?