[thorstenp] self as first argument of method

This commit is contained in:
Yann Leboulanger 2008-12-03 21:12:32 +00:00
parent 1d94f0fbff
commit 70abf6a955
1 changed files with 9 additions and 9 deletions

View File

@ -50,7 +50,7 @@ class Roster:
#print 'roster_zeroconf.py: diffs:' + str(diffs)
return diffs
def setItem(self, jid, name = '', groups = ''):
def setItem(self, jid, name='', groups=''):
#print 'roster_zeroconf.py: setItem %s' % jid
contact = self.zeroconf.get_contact(jid)
if not contact:
@ -60,7 +60,7 @@ class Roster:
txt = contact[8]
self._data[jid]={}
self._data[jid]['ask'] = 'no' #?
self._data[jid]['ask'] = 'none'
self._data[jid]['subscription'] = 'both'
self._data[jid]['groups'] = []
self._data[jid]['resources'] = {}
@ -98,7 +98,7 @@ class Roster:
if jid in self._data:
return self._data[jid]
def __getitem__(self,jid):
def __getitem__(self, jid):
#print 'roster_zeroconf.py: __getitem__'
return self._data[jid]
@ -138,23 +138,23 @@ class Roster:
#print 'roster_zeroconf.py: getShow'
return self.getStatus(jid)
def getPriority(jid):
def getPriority(self, jid):
return 5
def getSubscription(self,jid):
def getSubscription(self, jid):
#print 'roster_zeroconf.py: getSubscription'
return 'both'
def Subscribe(self,jid):
def Subscribe(self, jid):
pass
def Unsubscribe(self,jid):
def Unsubscribe(self, jid):
pass
def Authorize(self,jid):
def Authorize(self, jid):
pass
def Unauthorize(self,jid):
def Unauthorize(self, jid):
pass
# vim: se ts=3: