aboutsummaryrefslogtreecommitdiffstats
path: root/core/moduleapi.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2016-04-06 21:29:30 +0200
committerKim Alvefur <zash@zash.se>2016-04-06 21:29:30 +0200
commitc82d43ec124fcc2bc8a3c516a6f9ec838c64efef (patch)
tree5c285233d3ccf3522b93121d4560218cefa7416d /core/moduleapi.lua
parent86ece22c8cb2ffc73d8b22f7aa8a92bdb582a5f3 (diff)
downloadprosody-c82d43ec124fcc2bc8a3c516a6f9ec838c64efef.tar.gz
prosody-c82d43ec124fcc2bc8a3c516a6f9ec838c64efef.zip
moduleapi: Allow an origin session to be passed to module:send()
Diffstat (limited to 'core/moduleapi.lua')
-rw-r--r--core/moduleapi.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/moduleapi.lua b/core/moduleapi.lua
index 402c7927..21b2216c 100644
--- a/core/moduleapi.lua
+++ b/core/moduleapi.lua
@@ -374,8 +374,8 @@ function api:provides(name, item)
self:add_item(name.."-provider", item);
end
-function api:send(stanza)
- return core_post_stanza(hosts[self.host], stanza);
+function api:send(stanza, origin)
+ return core_post_stanza(origin or hosts[self.host], stanza);
end
function api:broadcast(jids, stanza, iter)