diff options
author | Morris Jobke <hey@morrisjobke.de> | 2018-02-26 17:12:57 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-26 17:12:57 +0100 |
commit | 612e875f609a89a09a2d0fa7c017f6f4f5b0e97d (patch) | |
tree | fdc15c30deb098fda96ae053f6ac00f8b06f5571 /apps/comments/lib | |
parent | 4154a565366cc805d51a3d6a8b8c11cde62f29f9 (diff) | |
parent | aeb7503febbae7213a234e7b5b35d3291f78e2f8 (diff) | |
download | nextcloud-server-612e875f609a89a09a2d0fa7c017f6f4f5b0e97d.tar.gz nextcloud-server-612e875f609a89a09a2d0fa7c017f6f4f5b0e97d.zip |
Merge pull request #8355 from nextcloud/fix-comments-num-index
Fix comments (and systemtags) when involving users with numerical ids
Diffstat (limited to 'apps/comments/lib')
-rw-r--r-- | apps/comments/lib/Activity/Listener.php | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/comments/lib/Activity/Listener.php b/apps/comments/lib/Activity/Listener.php index e9a41f8f6b2..b5378e996dc 100644 --- a/apps/comments/lib/Activity/Listener.php +++ b/apps/comments/lib/Activity/Listener.php @@ -98,7 +98,7 @@ class Listener { /** @var Node $node */ $node = array_shift($nodes); $al = $this->shareHelper->getPathsForAccessList($node); - $users = array_merge($users, $al['users']); + $users += $al['users']; } } @@ -119,7 +119,9 @@ class Listener { ]); foreach ($users as $user => $path) { - $activity->setAffectedUser($user); + // numerical user ids end up as integers from array keys, but string + // is required + $activity->setAffectedUser((string)$user); $activity->setSubject('add_comment_subject', [ 'actor' => $actor, |