diff options
-rw-r--r-- | ChangeLog | 2 | ||||
-rw-r--r-- | src/mod_pubsub/mod_pubsub.erl | 16 |
2 files changed, 11 insertions, 7 deletions
@@ -4,6 +4,8 @@ ejabberdctl usage example (EJAB-420) * doc/guide.html: Likewise + * src/mod_pubsub/mod_pubsub.erl: PEP notification bugfix + 2007-12-20 Badlop <badlop@process-one.net> * src/msgs/zh.msg: Small update (thanks to Shelley Shyan) diff --git a/src/mod_pubsub/mod_pubsub.erl b/src/mod_pubsub/mod_pubsub.erl index 2ce785f7c..194bc920a 100644 --- a/src/mod_pubsub/mod_pubsub.erl +++ b/src/mod_pubsub/mod_pubsub.erl @@ -2341,13 +2341,15 @@ broadcast_by_caps({LUser, LServer, LResource}, Node, _Type, Stanza) -> _ -> ok end, - %% also send a notification to any - %% of the account owner's available resources. - %% See: XEP-0163 1.1 section 3 - lists:foreach(fun(Resource) -> - To = jlib:make_jid(LUser, LServer, Resource), - ejabberd_router:route(Sender, To, Stanza) - end, SenderResources), + %% also send a notification to any + %% of the account owner's available resources. + %% See: XEP-0163 1.1 section 3 + %% Note: ejabberd_c2s:get_subscribed_and_online already returns owner online resources + %% this loop should be deleted + % lists:foreach(fun(Resource) -> + % To = jlib:make_jid(LUser, LServer, Resource), + % ejabberd_router:route(Sender, To, Stanza) + % end, SenderResources), ok; _ -> ok |