xep_0384: add helper to access .text
This commit is contained in:
parent
9a3effbe40
commit
78f42fde5c
1 changed files with 11 additions and 1 deletions
12
stanza.py
12
stanza.py
|
@ -132,7 +132,17 @@ class PreKeyPublic(ElementBase):
|
|||
namespace = OMEMO_BASE_NS
|
||||
name = 'preKeyPublic'
|
||||
plugin_attrib = name
|
||||
interfaces = {'preKeyId'}
|
||||
plugin_multi_attrib = 'prekeys'
|
||||
interfaces = {'preKeyId', 'value'}
|
||||
|
||||
def get_value(self):
|
||||
return self.xml.text
|
||||
|
||||
def set_value(self, value):
|
||||
self.xml.text = str(value)
|
||||
|
||||
def del_value(self):
|
||||
self.xml.text = ''
|
||||
|
||||
|
||||
register_stanza_plugin(Message, Encrypted)
|
||||
|
|
Loading…
Reference in a new issue