From e93af70b570cc7317da497f004efe85608a22c0d Mon Sep 17 00:00:00 2001 From: Badlop Date: Thu, 23 Feb 2017 21:29:55 +0100 Subject: [PATCH] Update to work with 17.03+ --- mod_rest/src/mod_rest.erl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mod_rest/src/mod_rest.erl b/mod_rest/src/mod_rest.erl index 6983745..42a35f1 100644 --- a/mod_rest/src/mod_rest.erl +++ b/mod_rest/src/mod_rest.erl @@ -145,8 +145,8 @@ ip_matches(ClientIp, AllowedValues) -> AllowedValues). post_request(Pkt) -> - mod_mam:user_send_packet(Pkt, #{jid => Pkt#message.from}, Pkt#message.from, Pkt#message.to), - case ejabberd_router:route(Pkt#message.from, Pkt#message.to, Pkt) of + mod_mam:user_send_packet({Pkt, #{jid => Pkt#message.from}}), + case ejabberd_router:route(Pkt) of ok -> {200, [], <<"Ok">>}; _ -> {500, [], <<"Error">>} end.