summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Romain <christophe.romain@process-one.net>2009-01-10 13:38:10 +0000
committerChristophe Romain <christophe.romain@process-one.net>2009-01-10 13:38:10 +0000
commit38dcae1fc86448384cd23a982492dba2e3641d85 (patch)
treea59cfba1fcceed56404cdb01b3f9a77c72ab98cb
parent* doc/guide.tex: Improve explanation of backup commands (EJAB-832) (diff)
fix unsubscription of full jid subscribed node (EJAB-839)
SVN Revision: 1794
-rw-r--r--ChangeLog5
-rw-r--r--src/mod_pubsub/node_default.erl3
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index f30084f0..ed215105 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2009-01-10 Christophe Romain <christophe.romain@process-one.net>
+
+ * src/mod_pubsub/node_default.erl: fix unsubscription of full jid
+ subscribed node (thanks to Andy Skelton)(EJAB-839)
+
2009-01-09 Badlop <badlop@process-one.net>
* doc/guide.tex: Improve explanation of backup commands (EJAB-832)
diff --git a/src/mod_pubsub/node_default.erl b/src/mod_pubsub/node_default.erl
index ae4717ce..9583b34a 100644
--- a/src/mod_pubsub/node_default.erl
+++ b/src/mod_pubsub/node_default.erl
@@ -372,11 +372,10 @@ unsubscribe_node(Host, Node, Sender, Subscriber, _SubId) ->
(not Authorized) and (Affiliation =/= owner) ->
{error, ?ERR_FORBIDDEN};
%% Was just subscriber, remove the record
- Affiliation == none ->
+ SubState#pubsub_state.affiliation == none ->
del_state(SubState#pubsub_state.stateid),
{result, default};
true ->
- %% TODO, may require better clean
set_state(SubState#pubsub_state{subscription = none}),
{result, default}
end.