25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-22 16:20:52 +01:00
SVN Revision: 1806
This commit is contained in:
Pablo Polvorin 2009-01-12 15:51:22 +00:00
parent 56bccce713
commit 96c0ff44f9
2 changed files with 6 additions and 2 deletions

View File

@ -1,3 +1,7 @@
2009-01-11 Pablo Polvorin <pablo.polvorin@process-one.net>
* src/mod_pubsub/mod_pubsub.erl: Fix typo.
2009-01-11 Christophe Romain <christophe.romain@process-one.net>
* src/mod_pubsub/mod_pubsub.erl: fix owners cache and fix unsubscribe

View File

@ -1896,7 +1896,7 @@ set_affiliations(Host, Node, From, EntitiesEls) ->
error ->
{error, 'bad-request'};
_ ->
Action = fun(#pubsub_node{type = Type, owners = Owners}) ->
Action = fun(#pubsub_node{type = Type, owners = Owners}=N) ->
case lists:member(Owner, Owners) of
true ->
lists:foreach(
@ -1908,7 +1908,7 @@ set_affiliations(Host, Node, From, EntitiesEls) ->
NewOwners = [NewOwner|Owners],
tree_call(Host, set_node, [N#pubsub_node{owners = NewOwners}]);
none ->
NewOwner = jlib:short_prepd_bare_jid(JID),
OldOwner = jlib:short_prepd_bare_jid(JID),
case lists:member(OldOwner, Owners) of
true ->
NewOwners = Owners--[OldOwner],