diff options
author | mathieui <mathieui@mathieui.net> | 2021-07-03 11:09:41 +0200 |
---|---|---|
committer | mathieui <mathieui@mathieui.net> | 2021-07-03 11:17:15 +0200 |
commit | 7d4172808fb1ecee42da29211aa3b48b986902b3 (patch) | |
tree | d779350b1fdf2bf8446365f295cdf4f13db4cfd0 /slixmpp/stanza/stream_error.py | |
parent | 95b034797f07a9c9ca0041a12f1455114a98a21b (diff) | |
download | slixmpp-7d4172808fb1ecee42da29211aa3b48b986902b3.tar.gz slixmpp-7d4172808fb1ecee42da29211aa3b48b986902b3.tar.bz2 slixmpp-7d4172808fb1ecee42da29211aa3b48b986902b3.tar.xz slixmpp-7d4172808fb1ecee42da29211aa3b48b986902b3.zip |
stanza: add typing
Diffstat (limited to 'slixmpp/stanza/stream_error.py')
-rw-r--r-- | slixmpp/stanza/stream_error.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/slixmpp/stanza/stream_error.py b/slixmpp/stanza/stream_error.py index 0e728c8e..d2036a3c 100644 --- a/slixmpp/stanza/stream_error.py +++ b/slixmpp/stanza/stream_error.py @@ -62,13 +62,13 @@ class StreamError(Error, StanzaBase): 'system-shutdown', 'undefined-condition', 'unsupported-encoding', 'unsupported-feature', 'unsupported-stanza-type', 'unsupported-version'} - condition_ns = 'urn:ietf:params:xml:ns:xmpp-streams' + condition_ns: str = 'urn:ietf:params:xml:ns:xmpp-streams' - def get_see_other_host(self): + def get_see_other_host(self) -> str: ns = self.condition_ns return self._get_sub_text('{%s}see-other-host' % ns, '') - def set_see_other_host(self, value): + def set_see_other_host(self, value: str) -> None: if value: del self['condition'] ns = self.condition_ns @@ -76,5 +76,5 @@ class StreamError(Error, StanzaBase): elif self['condition'] == 'see-other-host': del self['condition'] - def del_see_other_host(self): + def del_see_other_host(self) -> None: self._del_sub('{%s}see-other-host' % self.condition_ns) |