mirror of
https://github.com/correl/SleekXMPP.git
synced 2024-11-27 19:19:54 +00:00
Fixed error in setState() method.
This commit is contained in:
parent
6041cd1952
commit
309c9e74eb
1 changed files with 3 additions and 2 deletions
|
@ -38,8 +38,9 @@ class ChatState(ElementBase):
|
|||
def setState(self, state):
|
||||
if state in self.states:
|
||||
self.name = state
|
||||
self.xml.tag = state
|
||||
self.xml.attrib['xmlns'] = self.namespace
|
||||
self.xml.tag = '{%s}%s' % (self.namespace, state)
|
||||
else:
|
||||
raise ValueError('Invalid chat state')
|
||||
|
||||
def getState(self):
|
||||
return self.name
|
||||
|
|
Loading…
Reference in a new issue