diff options
author | Matthew Wild <mwild1@gmail.com> | 2013-08-12 10:27:08 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2013-08-12 10:27:08 +0100 |
commit | 056eec9953383a5a5418e1cbf8fb89c07fb0e903 (patch) | |
tree | 936410a439862e025010cbfc036f38b21fb2af89 /util | |
parent | e0216573ab30d11b54056a9fe4b43293ebf0a910 (diff) | |
download | prosody-056eec9953383a5a5418e1cbf8fb89c07fb0e903.tar.gz prosody-056eec9953383a5a5418e1cbf8fb89c07fb0e903.zip |
util.async: Make functions local
Diffstat (limited to 'util')
-rw-r--r-- | util/async.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util/async.lua b/util/async.lua index 9036a876..59d3c6f2 100644 --- a/util/async.lua +++ b/util/async.lua @@ -22,7 +22,7 @@ local function runner_continue(thread) 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 @@ local function runner_create_thread(func, self) 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); |