summaryrefslogtreecommitdiff
path: root/poezio/common.py
diff options
context:
space:
mode:
Diffstat (limited to 'poezio/common.py')
-rw-r--r--poezio/common.py18
1 files changed, 0 insertions, 18 deletions
diff --git a/poezio/common.py b/poezio/common.py
index f80555ac..d4d09f9f 100644
--- a/poezio/common.py
+++ b/poezio/common.py
@@ -459,24 +459,6 @@ def format_gaming_string(infos: Dict[str, str]) -> str:
return name
-def safeJID(*args: Any, **kwargs: Any) -> JID:
- """
- Construct a :py:class:`slixmpp.JID` object from a string.
-
- Used to avoid tracebacks during is stringprep fails
- (fall back to a JID with an empty string).
- """
- try:
- return JID(*args, **kwargs)
- except InvalidJID:
- log.debug(
- 'safeJID caught an invalidJID exception: %r, %r',
- args, kwargs,
- exc_info=True,
- )
- return JID('')
-
-
def unique_prefix_of(a: str, b: str) -> str:
"""
Return the unique prefix of `a` with `b`.