Commit 3516016f authored by mathieui's avatar mathieui

typing: reorder jid.bare setter

parent a57aae79
......@@ -354,6 +354,15 @@ class JID:
def bare(self) -> str:
return self._bare
@bare.setter
def bare(self, value: str):
node, domain, resource = _parse_jid(value)
assert not resource
self._node = node
self._domain = domain
self._update_bare_full()
@property
def node(self) -> str:
return self._node
......@@ -372,14 +381,6 @@ class JID:
self._domain = _validate_domain(value)
self._update_bare_full()
@bare.setter
def bare(self, value: str):
node, domain, resource = _parse_jid(value)
assert not resource
self._node = node
self._domain = domain
self._update_bare_full()
@property
def resource(self) -> str:
return self._resource
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment