mod_cloud_notify: fix prosody 0.9 compatibility
authortmolitor <thilo@eightysoft.de>
Sun, 16 Jun 2019 02:00:34 +0200
changeset 3626 21f870e1ba55
parent 3625 c2c851722a8a
child 3627 da2d58208574
mod_cloud_notify: fix prosody 0.9 compatibility
mod_cloud_notify/mod_cloud_notify.lua
--- a/mod_cloud_notify/mod_cloud_notify.lua	Sun Jun 16 02:00:12 2019 +0200
+++ b/mod_cloud_notify/mod_cloud_notify.lua	Sun Jun 16 02:00:34 2019 +0200
@@ -99,7 +99,7 @@
 		if stopped then return; end
 		return callback(t);
 	end);
-	if timer.stop then return timer; end		-- new prosody api includes stop() function
+	if timer and timer.stop then return timer; end		-- new prosody api includes stop() function
 	return {
 		stop = function () stopped = true end;
 		timer;