Don't perform caps lookup if the disco info is already known.

This commit is contained in:
Lance Stout 2012-09-11 20:28:28 -07:00
parent 0016d9a638
commit 26fa9bd87e

View file

@ -143,6 +143,11 @@ class XEP_0115(BasePlugin):
if str(existing_verstring) == str(pres['caps']['ver']):
return
existing_caps = self.get_caps(verstring=pres['caps']['ver'])
if existing_caps is not None:
self.assign_verstring(pres['from'], pres['caps']['ver'])
return
if pres['caps']['hash'] not in self.hashes:
try:
log.debug("Unknown caps hash: %s", pres['caps']['hash'])