From 5d476c9a51813dd52a407e0c6254b6a13e669a64 Mon Sep 17 00:00:00 2001 From: Alexkurd Date: Fri, 29 Jan 2016 14:28:07 +0300 Subject: [PATCH] Update hubFrontendCommentsAdd.controller.php MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Не отправлять уведомление на почту автору комментария --- lib/actions/frontend/hubFrontendCommentsAdd.controller.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/actions/frontend/hubFrontendCommentsAdd.controller.php b/lib/actions/frontend/hubFrontendCommentsAdd.controller.php index 7c482ee..5a6192b 100644 --- a/lib/actions/frontend/hubFrontendCommentsAdd.controller.php +++ b/lib/actions/frontend/hubFrontendCommentsAdd.controller.php @@ -123,7 +123,7 @@ private function getParentId() protected function sendNotifications($comment) { $view = wa()->getView(); - + $userId = wa()->getUser()->getId(); $topic = $comment['topic']; $topic['url'] = wa()->getRouteUrl( @@ -140,7 +140,7 @@ protected function sendNotifications($comment) $following_model = new hubFollowingModel(); foreach ($following_model->getFollowers($comment['topic']['id'], true) as $c) { - if (empty($c['email'])) { + if (empty($c['email']) || $userId == $comment['contact_id']) { continue; } $view->assign('contact', $c);