summaryrefslogtreecommitdiff
path: root/sleekxmpp/plugins/xep_0199
diff options
context:
space:
mode:
authorLance Stout <lancestout@gmail.com>2011-02-24 16:19:45 -0500
committerLance Stout <lancestout@gmail.com>2011-02-24 16:19:45 -0500
commit42c8f6ae877535c48424e5bcb8233f5d07dcfb7d (patch)
tree5d6892cfd29cb009b952bc06b398bd8cf03ac541 /sleekxmpp/plugins/xep_0199
parente4f3b777f9d6c57a2d05296079828609e6b18375 (diff)
parent45ccb313560fbfbc0354ebac9116ecb9ff963a47 (diff)
downloadslixmpp-42c8f6ae877535c48424e5bcb8233f5d07dcfb7d.tar.gz
slixmpp-42c8f6ae877535c48424e5bcb8233f5d07dcfb7d.tar.bz2
slixmpp-42c8f6ae877535c48424e5bcb8233f5d07dcfb7d.tar.xz
slixmpp-42c8f6ae877535c48424e5bcb8233f5d07dcfb7d.zip
Merge branch 'develop' into roster
Diffstat (limited to 'sleekxmpp/plugins/xep_0199')
-rw-r--r--sleekxmpp/plugins/xep_0199/ping.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/sleekxmpp/plugins/xep_0199/ping.py b/sleekxmpp/plugins/xep_0199/ping.py
index 064af4ca..d1e08e61 100644
--- a/sleekxmpp/plugins/xep_0199/ping.py
+++ b/sleekxmpp/plugins/xep_0199/ping.py
@@ -54,7 +54,7 @@ class xep_0199(base_plugin):
self.xep = '0199'
self.stanza = stanza
- self.keepalive = self.config.get('keepalive', True)
+ self.keepalive = self.config.get('keepalive', False)
self.frequency = float(self.config.get('frequency', 300))
self.timeout = self.config.get('timeout', 30)
@@ -90,7 +90,7 @@ class xep_0199(base_plugin):
"""Send ping request to the server."""
log.debug("Pinging...")
resp = self.send_ping(self.xmpp.boundjid.host, self.timeout)
- if not resp:
+ if resp is None or resp is False:
log.debug("Did not recieve ping back in time." + \
"Requesting Reconnect.")
self.xmpp.reconnect()
@@ -160,4 +160,4 @@ class xep_0199(base_plugin):
# Backwards compatibility for names
-Ping.sendPing = Ping.send_ping
+xep_0199.sendPing = xep_0199.send_ping