Skip to content

Commit

Permalink
Merge pull request #990 from nextcloud/notificatoin-hide-username
Browse files Browse the repository at this point in the history
Hide usernames if results are hidden
  • Loading branch information
dartcafe authored Jul 7, 2020
2 parents cf3e219 + eb89a6d commit 3c965b1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Service/MailService.php
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ public function sendNotifications() {

foreach ($log as $logItem) {
if ($logItem->getPollId() === $subscription->getPollId()) {
if ($poll->getAnonymous()) {
if ($poll->getAnonymous() || $poll->getShowResults() !== "always") {
$displayUser = "A user";
} elseif ($this->userManager->get($logItem->getUserId()) instanceof IUser) {
$displayUser = $this->userManager->get($logItem->getUserId())->getDisplayName();
Expand Down

0 comments on commit 3c965b1

Please sign in to comment.