diff options
| author | Zeyla Hellyer <[email protected]> | 2018-05-23 21:11:00 -0700 |
|---|---|---|
| committer | Zeyla Hellyer <[email protected]> | 2018-05-23 21:11:00 -0700 |
| commit | 4a24c9004a1aac31eb552e5cdef6e986a6e903b3 (patch) | |
| tree | 3318164c35593528c9ab56be0b227a56de55aa3a /src/model | |
| parent | Fix links to the repo (diff) | |
| download | serenity-4a24c9004a1aac31eb552e5cdef6e986a6e903b3.tar.xz serenity-4a24c9004a1aac31eb552e5cdef6e986a6e903b3.zip | |
Implement Mentionable for CurrentUser
Diffstat (limited to 'src/model')
| -rw-r--r-- | src/model/misc.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/model/misc.rs b/src/model/misc.rs index 183ddc3..5278f89 100644 --- a/src/model/misc.rs +++ b/src/model/misc.rs @@ -36,6 +36,12 @@ impl Mentionable for Channel { } } +impl Mentionable for CurrentUser { + fn mention(&self) -> String { + format!("<@{}>", self.id.0) + } +} + impl Mentionable for Emoji { fn mention(&self) -> String { format!("<:{}:{}>", self.name, self.id.0) } } |