diff options
author | Matthew Wild <mwild1@gmail.com> | 2018-10-26 19:32:00 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2018-10-26 19:32:00 +0100 |
commit | 9b5c6c4d9de2d32a3a0391e6d06a178f21dbb807 (patch) | |
tree | 0eff02506e6364d1dcb5c71b2edaacd6662ffe20 /util/promise.lua | |
parent | 3bc2c02797799a0e71c4a04dc810d2d683271c42 (diff) | |
download | prosody-9b5c6c4d9de2d32a3a0391e6d06a178f21dbb807.tar.gz prosody-9b5c6c4d9de2d32a3a0391e6d06a178f21dbb807.zip |
Many things: switch from hacky multi-arg xpcall implementations to a standard util.xpcall
Diffstat (limited to 'util/promise.lua')
-rw-r--r-- | util/promise.lua | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/util/promise.lua b/util/promise.lua index b368f34e..07c9c4dc 100644 --- a/util/promise.lua +++ b/util/promise.lua @@ -1,6 +1,8 @@ local promise_methods = {}; local promise_mt = { __name = "promise", __index = promise_methods }; +local xpcall = require "util.xpcall".xpcall; + function promise_mt:__tostring() return "promise (" .. (self._state or "invalid") .. ")"; end |