aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar jesopo2019-09-09 21:35:54 +0100
committerGravatar jesopo2019-09-09 21:35:54 +0100
commita9d11fc7f8d2b5244d21b75efe59d352468e121f (patch)
tree3409dc4c2c989d69f3692999a79b31f5b6813bf0
parentadd !unsilence (diff)
signature
use rpartition, not partition, to avoid splitting on leading @
-rw-r--r--modules/fediverse.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/fediverse.py b/modules/fediverse.py
index bcf5c7dc..f371f568 100644
--- a/modules/fediverse.py
+++ b/modules/fediverse.py
@@ -10,7 +10,7 @@ ACTIVITY_HEADERS = {"Accept": ("application/ld+json; "
'profile="https://www.w3.org/ns/activitystreams"')}
def _parse_username(s):
- username, _, instance = s.partition("@")
+ username, _, instance = s.rpartition("@")
if username.startswith("@"):
username = username[1:]
if username and instance: