Replaced empty UserNotification object before sending email notifications
authorMarcel Werk <burntime@woltlab.com>
Thu, 14 Jul 2016 15:07:29 +0000 (17:07 +0200)
committerMarcel Werk <burntime@woltlab.com>
Thu, 14 Jul 2016 15:07:35 +0000 (17:07 +0200)
wcfsetup/install/files/lib/system/user/notification/UserNotificationHandler.class.php

index 815fde60621b786e85389a236fcfb3705f88e6d5..ce8ef8d62cc58e19f1c0cb612f8a230b0e8e9f3b 100644 (file)
@@ -230,6 +230,10 @@ class UserNotificationHandler extends SingletonFactory {
                                foreach ($recipients as $recipient) {
                                        if ($recipient->mailNotificationType == 'instant') {
                                                if (isset($notifications[$recipient->userID]) && $notifications[$recipient->userID]['isNew']) {
+                                                       // update UserNotification object
+                                                       $event->setObject($notifications[$recipient->userID]['object'], $notificationObject, $userProfile, $additionalData);
+                                                       
+                                                       // send notification
                                                        $this->sendInstantMailNotification($notifications[$recipient->userID]['object'], $recipient, $event);
                                                }
                                        }