Strip displayname format in Matrix->Telegram non-username mentions. Fixes #138

This commit is contained in:
Tulir Asokan
2018-12-20 16:45:40 +02:00
parent 1bebdcba89
commit 75b6e4f633
3 changed files with 18 additions and 6 deletions
+4
View File
@@ -97,6 +97,10 @@ class User(AbstractUser):
def displayname(self) -> str:
return self.mxid_localpart
@property
def plain_displayname(self) -> str:
return self.displayname
@property
def db_contacts(self) -> List[DBContact]:
return [self.db.merge(DBContact(user=self.tgid, contact=puppet.id))