Пример #1
0
def addUser(jid):
	jid = unicode(jid.getStripped())
	iMan.set_entry('roster', jid, "last_login", time.time())
	iMan.set_entry('roster', jid, "last_message", time.time())
	set_attr(jid, 'rank', const.RANK_USER)
Пример #2
0
def set_attr(jid, attr, rank):
	"""Set 'jid's attr to value."""
	return iMan.set_entry('roster', jid, attr, value)