aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2018-10-25 15:24:52 +0100
committerMatthew Wild <mwild1@gmail.com>2018-10-25 15:24:52 +0100
commitdd74a38b22fe0424ea2fd29ac2ec5cbb3bef46dc (patch)
treec362a3c6ca2861d61f457879b4b2a028257f9f89 /util
parente7a26ebc24cc8e22c84108ec8c6e94a1f1f1bc63 (diff)
downloadprosody-dd74a38b22fe0424ea2fd29ac2ec5cbb3bef46dc.tar.gz
prosody-dd74a38b22fe0424ea2fd29ac2ec5cbb3bef46dc.zip
util.promise: Fix missing parameters
Diffstat (limited to 'util')
-rw-r--r--util/promise.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/promise.lua b/util/promise.lua
index fa09a01c..14521c4a 100644
--- a/util/promise.lua
+++ b/util/promise.lua
@@ -31,11 +31,11 @@ local function next_pending(self, on_fulfilled, on_rejected, resolve, reject)
end
local function next_fulfilled(promise, on_fulfilled, on_rejected, resolve, reject) -- luacheck: ignore 212/on_rejected
- wrap_handler(on_fulfilled, resolve, reject)(promise.value);
+ wrap_handler(on_fulfilled, resolve, reject, resolve)(promise.value);
end
local function next_rejected(promise, on_fulfilled, on_rejected, resolve, reject) -- luacheck: ignore 212/on_fulfilled
- wrap_handler(on_rejected, resolve, reject)(promise.reason);
+ wrap_handler(on_rejected, resolve, reject, reject)(promise.reason);
end
local function promise_settle(promise, new_state, new_next, cbs, value)