gears.timer: Don't assert() that no error occured

The whole point of this pcall() is that we do not have unprotected Lua errors,
because those kill awesome. So instead of assert()ing, let's just print a
message.

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
Uli Schlachter 2015-01-10 16:53:59 +01:00
parent 0f02ed0e15
commit a36ddb68e1
1 changed files with 3 additions and 1 deletions

View File

@ -33,7 +33,9 @@ function timer:start()
local success, message = pcall(function()
self:emit_signal("timeout")
end)
assert(success, message)
if not success then
print(message)
end
return true
end)
end