diff options
author | Joas Schilling <coding@schilljs.com> | 2021-01-14 19:14:23 +0300 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2021-02-02 15:52:24 +0300 |
commit | dd06f39ee5eccdb29955136c6713c253f65b4ec4 (patch) | |
tree | 8e6d475e0271a7445d8e9e3a42eb552c435dde2c /lib/Chat/Parser/SystemMessage.php | |
parent | bfbce8d714ded49e5f840926e25e161dc4710015 (diff) |
Add an endpoint to delete a message
For now it only creates a system message
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Chat/Parser/SystemMessage.php')
-rw-r--r-- | lib/Chat/Parser/SystemMessage.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Chat/Parser/SystemMessage.php b/lib/Chat/Parser/SystemMessage.php index 74acd0688..306e78ab4 100644 --- a/lib/Chat/Parser/SystemMessage.php +++ b/lib/Chat/Parser/SystemMessage.php @@ -354,6 +354,11 @@ class SystemMessage { if ($currentUserIsActor) { $parsedMessage = $this->l->t('You stopped Matterbridge.'); } + } elseif ($message === 'message_deleted') { + $parsedMessage = $this->l->t('{actor} deleted a message'); + if ($currentUserIsActor) { + $parsedMessage = $this->l->t('You deleted a message'); + } } else { throw new \OutOfBoundsException('Unknown subject'); } |