From 7c2b9eaf979fec441facd4d60a2707b7853ca0e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20K=C3=B6hler?= Date: Fri, 5 Nov 2010 11:42:32 +0100 Subject: Correct privacy check direction in mod_last (EJAB-1339) The change for EJAB-1271 to change the direction of the privacy check from out to in violates the idea that the check should imitate a subscription state check of from. Rather correct the order of the From and To parameters. --- src/mod_last.erl | 4 ++-- src/mod_last_odbc.erl | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/mod_last.erl b/src/mod_last.erl index d3b561f60..c2a79fb2a 100644 --- a/src/mod_last.erl +++ b/src/mod_last.erl @@ -125,9 +125,9 @@ process_sm_iq(From, To, #iq{type = Type, sub_el = SubEl} = IQ) -> privacy_check_packet, Server, allow, [User, Server, UserListRecord, - {From, To, + {To, From, {xmlelement, "presence", [], []}}, - in]) of + out]) of allow -> get_last(IQ, SubEl, User, Server); deny -> diff --git a/src/mod_last_odbc.erl b/src/mod_last_odbc.erl index 7616c5020..b22da5ffd 100644 --- a/src/mod_last_odbc.erl +++ b/src/mod_last_odbc.erl @@ -117,9 +117,9 @@ process_sm_iq(From, To, #iq{type = Type, sub_el = SubEl} = IQ) -> privacy_check_packet, Server, allow, [User, Server, UserListRecord, - {From, To, + {To, From, {xmlelement, "presence", [], []}}, - in]) of + out]) of allow -> get_last(IQ, SubEl, User, Server); deny -> -- cgit v1.2.3