summaryrefslogtreecommitdiff
path: root/app/Subscriber
diff options
context:
space:
mode:
authorFrédéric Guillot <fred@kanboard.net>2015-01-02 21:48:26 -0500
committerFrédéric Guillot <fred@kanboard.net>2015-01-02 21:48:26 -0500
commit0ebdd4ddfd898628cc30e34e55e97f88e5e30a71 (patch)
tree4038cd9ad1ad440b033d221b4ffd637ec03a538d /app/Subscriber
parent45c95d74fc2115fe4cc7214553c0927d3ce9df8d (diff)
Cleanup and fixes
Diffstat (limited to 'app/Subscriber')
-rw-r--r--app/Subscriber/NotificationSubscriber.php4
-rw-r--r--app/Subscriber/ProjectActivitySubscriber.php4
2 files changed, 4 insertions, 4 deletions
diff --git a/app/Subscriber/NotificationSubscriber.php b/app/Subscriber/NotificationSubscriber.php
index 4412636f..1580f6dc 100644
--- a/app/Subscriber/NotificationSubscriber.php
+++ b/app/Subscriber/NotificationSubscriber.php
@@ -44,13 +44,13 @@ class NotificationSubscriber extends Base implements EventSubscriberInterface
);
}
- public function execute(GenericEvent $event)
+ public function execute(GenericEvent $event, $event_name)
{
$values = $this->getTemplateData($event);
$users = $this->notification->getUsersList($values['task']['project_id']);
if ($users) {
- $this->notification->sendEmails($this->templates[$event->getName()], $users, $values);
+ $this->notification->sendEmails($this->templates[$event_name], $users, $values);
}
}
diff --git a/app/Subscriber/ProjectActivitySubscriber.php b/app/Subscriber/ProjectActivitySubscriber.php
index 3daf2f4d..aae09ae2 100644
--- a/app/Subscriber/ProjectActivitySubscriber.php
+++ b/app/Subscriber/ProjectActivitySubscriber.php
@@ -27,7 +27,7 @@ class ProjectActivitySubscriber extends Base implements EventSubscriberInterface
);
}
- public function execute(GenericEvent $event)
+ public function execute(GenericEvent $event, $event_name)
{
// Executed only when someone is logged
if ($this->userSession->isLogged() && isset($event['task_id'])) {
@@ -38,7 +38,7 @@ class ProjectActivitySubscriber extends Base implements EventSubscriberInterface
$values['task']['project_id'],
$values['task']['id'],
$this->userSession->getId(),
- $event->getName(),
+ $event_name,
$values
);
}