diff options
author | 2020-12-21 19:39:21 +0000 | |
---|---|---|
committer | 2020-12-21 19:39:21 +0000 | |
commit | 443a322b553ce38d3cde67798ee3b7c19aa9fbeb (patch) | |
tree | 8118454e1861939e813d77887e7a823446fa21d1 /backend/authentication | |
parent | Update review-policy.yml (diff) | |
parent | Merge branch 'main' into discord-webhook (diff) |
Merge pull request #39 from python-discord/discord-webhook
Diffstat (limited to 'backend/authentication')
-rw-r--r-- | backend/authentication/user.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/backend/authentication/user.py b/backend/authentication/user.py index 722c348..f40c68c 100644 --- a/backend/authentication/user.py +++ b/backend/authentication/user.py @@ -19,3 +19,7 @@ class User(BaseUser): def display_name(self) -> str: """Return username and discriminator as display name.""" return f"{self.payload['username']}#{self.payload['discriminator']}" + + @property + def discord_mention(self) -> str: + return f"<@{self.payload['id']}>" |