change(s) from xmpppy

This commit is contained in:
Dimitur Kirov 2006-04-08 15:39:37 +00:00
parent 039a74adff
commit 6556d01cbe
3 changed files with 5 additions and 2 deletions

View File

@ -415,3 +415,6 @@ class Debug:
return 0
DBG_ALWAYS='always'
##Uncomment this to effectively disable all debugging and all debugging overhead.
#Debug=NoDebug

View File

@ -37,7 +37,7 @@ def _discover(disp,ns,jid,node=None,fb2b=0,fb2a=1):
and if it doesnt support browse (or fb2b is not true) fall back to agents protocol
(if gb2a is true). Returns obtained info. Used internally. """
iq=Iq(to=jid,typ='get',queryNS=ns)
if node: iq.setAttr('node',node)
if node: iq.setQuerynode(node)
rep=disp.SendAndWaitForResponse(iq)
if fb2b and not isResultNode(rep): rep=disp.SendAndWaitForResponse(Iq(to=jid,typ='get',queryNS=NS_BROWSE)) # Fallback to browse
if fb2a and not isResultNode(rep): rep=disp.SendAndWaitForResponse(Iq(to=jid,typ='get',queryNS=NS_AGENTS)) # Fallback to agents

View File

@ -33,7 +33,7 @@ def _discover(disp, ns, jid, node = None, fb2b=0, fb2a=1, cb=None):
(if gb2a is true). Returns obtained info. Used internally. """
iq=Iq(to=jid, typ='get', queryNS=ns)
if node:
iq.setAttr('node',node)
iq.setQuerynode(node)
def _on_resp1(resp):
if fb2b and not isResultNode(resp):
# Fallback to browse