add fireEvent-Event
authorJoshua Rüsweg <josh@bastelstu.be>
Thu, 3 Sep 2015 20:31:48 +0000 (22:31 +0200)
committerJoshua Rüsweg <josh@bastelstu.be>
Thu, 3 Sep 2015 20:31:48 +0000 (22:31 +0200)
wcfsetup/install/files/lib/system/user/notification/UserNotificationHandler.class.php

index f7fc6f291e0b3c624676af09d960701694ce1f69..da8d676891e284de24a42df6c71b1f41b8d27860 100644 (file)
@@ -10,6 +10,7 @@ use wcf\data\user\UserEditor;
 use wcf\data\user\UserProfile;
 use wcf\system\cache\builder\UserNotificationEventCacheBuilder;
 use wcf\system\database\util\PreparedStatementConditionBuilder;
+use wcf\system\event\EventHandler;
 use wcf\system\exception\SystemException;
 use wcf\system\mail\Mail;
 use wcf\system\user\notification\event\IUserNotificationEvent;
@@ -105,6 +106,18 @@ class UserNotificationHandler extends SingletonFactory {
                // set object data
                $event->setObject(new UserNotification(null, array()), $notificationObject, $userProfile, $additionalData);
                
+               EventHandler::getInstance()->fireAction($this, 'fireEvent', array(
+                       'eventName' => $eventName,
+                       'objectType' => $objectType,
+                       'notificationObject' => $notificationObject,
+                       'recipientIDs' => $recipientIDs,
+                       'additionalData' => $additionalData,
+                       'baseObjectID' => $baseObjectID,
+                       'objectTypeObject' => $objectTypeObject,
+                       'userProfile' => $userProfile,
+                       'event' => $event
+               ));
+               
                // find existing notifications
                $conditions = new PreparedStatementConditionBuilder();
                $conditions->add("userID IN (?)", array($recipientIDs));