From: Florian Zeitz Date: Sun, 22 Mar 2009 02:49:37 +0000 (+0100) Subject: Ignore own PEP events X-Git-Url: https://cgit.babelmonkeys.de/?a=commitdiff_plain;h=0c21f38f39f62a27f30274204f575d56efa397d7;p=socialXMPP.git Ignore own PEP events --- diff --git a/scripts/basic.js b/scripts/basic.js index b7e597b..06ff778 100644 --- a/scripts/basic.js +++ b/scripts/basic.js @@ -142,6 +142,9 @@ function genCaps() { function _cbPEP(e) { var from = e.getAttribute('from'); + if (Strophe.getBareJidFromJid(from) == Strophe.getBareJidFromJid(connection.jid)) { + return true; // Drop own PEP events + } var items = e.getElementsByTagName('items')[0]; // Handle Tune if (items.getAttribute('node') == NS_TUNE) {