mirror of
https://github.com/kikito/cron.lua.git
synced 2024-12-19 18:34:20 +00:00
Fix deprecated function call
This commit is contained in:
parent
bedcb48355
commit
534298daeb
4
cron.lua
4
cron.lua
@ -68,7 +68,7 @@ local function updateAfterClock(self, dt) -- returns true if expired
|
||||
self.running = self.running + dt
|
||||
|
||||
if self.running >= self.time then
|
||||
self.callback(unpack(self.args))
|
||||
self.callback(table.unpack(self.args))
|
||||
return true
|
||||
end
|
||||
return false
|
||||
@ -80,7 +80,7 @@ local function updateEveryClock(self, dt)
|
||||
self.running = self.running + dt
|
||||
|
||||
while self.running >= self.time do
|
||||
self.callback(unpack(self.args))
|
||||
self.callback(table.unpack(self.args))
|
||||
self.running = self.running - self.time
|
||||
end
|
||||
return false
|
||||
|
Loading…
Reference in New Issue
Block a user