diff options
author | Vitor Mattos <vitor@php.rio> | 2021-12-19 18:11:35 -0300 |
---|---|---|
committer | Vitor Mattos <vitor@php.rio> | 2022-01-21 08:37:04 -0300 |
commit | 9efbc9c1d533fb970a5cd89f154e3a4fb7ff882d (patch) | |
tree | fd5fdf014a86948e0b87a864d7c3a6fb29a76889 /lib/private/Comments/Comment.php | |
parent | 58798b835a1d57edf55ba9a2a319b15579fe82ce (diff) | |
download | nextcloud-server-9efbc9c1d533fb970a5cd89f154e3a4fb7ff882d.tar.gz nextcloud-server-9efbc9c1d533fb970a5cd89f154e3a4fb7ff882d.zip |
Add comments reactions
Signed-off-by: Vitor Mattos <vitor@php.rio>
Diffstat (limited to 'lib/private/Comments/Comment.php')
-rw-r--r-- | lib/private/Comments/Comment.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/private/Comments/Comment.php b/lib/private/Comments/Comment.php index 5cf04092101..2b338efc75f 100644 --- a/lib/private/Comments/Comment.php +++ b/lib/private/Comments/Comment.php @@ -44,6 +44,7 @@ class Comment implements IComment { 'referenceId' => null, 'creationDT' => null, 'latestChildDT' => null, + 'reactions' => null, ]; /** @@ -431,6 +432,21 @@ class Comment implements IComment { } /** + * @inheritDoc + */ + public function getReactions(): array { + return $this->data['reactions'] ?? []; + } + + /** + * @inheritDoc + */ + public function setReactions(?array $reactions): IComment { + $this->data['reactions'] = $reactions; + return $this; + } + + /** * sets the comment data based on an array with keys as taken from the * database. * |