util/async.lua
changeset 5790 959163e4d631
parent 5788 3556f338caa3
child 5791 2c98061b6b1e
--- a/util/async.lua	Sun Aug 11 14:46:27 2013 +0100
+++ b/util/async.lua	Mon Aug 12 10:27:08 2013 +0100
@@ -22,7 +22,7 @@
 	return true;
 end
 
-function waiter(num)
+local function waiter(num)
 	local thread = coroutine.running();
 	if not thread then
 		error("Not running in an async context, see http://prosody.im/doc/developers/async");
@@ -54,7 +54,7 @@
 end
 
 local empty_watchers = {};
-function runner(func, watchers, data)
+local function runner(func, watchers, data)
 	return setmetatable({ func = func, thread = false, state = "ready", notified_state = "ready",
 		queue = {}, watchers = watchers or empty_watchers, data = data }
 	, runner_mt);