aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathan Guse <nathaniel.guse@gmail.com>2013-01-15 12:29:20 -0600
committerNathan Guse <nathaniel.guse@gmail.com>2013-01-15 12:29:20 -0600
commitf089e099fed38b1bdae5316fb09f0c8ed847d495 (patch)
tree8ca4d1d78114c8bb28027c6fb1f65e6cfe8cce80
parent07282a30ae077825ea81a4e26839ac0473dc97b7 (diff)
downloadforums-f089e099fed38b1bdae5316fb09f0c8ed847d495.tar
forums-f089e099fed38b1bdae5316fb09f0c8ed847d495.tar.gz
forums-f089e099fed38b1bdae5316fb09f0c8ed847d495.tar.bz2
forums-f089e099fed38b1bdae5316fb09f0c8ed847d495.tar.xz
forums-f089e099fed38b1bdae5316fb09f0c8ed847d495.zip
[ticket/11103] Including the set call in the declaration throws errors
Call the set_notification_manager from the load_object function instead. PHPBB3-11103
-rw-r--r--phpBB/config/notifications.yml34
-rw-r--r--phpBB/includes/notification/manager.php9
2 files changed, 8 insertions, 35 deletions
diff --git a/phpBB/config/notifications.yml b/phpBB/config/notifications.yml
index c8414cb031..60aa63a854 100644
--- a/phpBB/config/notifications.yml
+++ b/phpBB/config/notifications.yml
@@ -28,8 +28,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -48,8 +46,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -68,8 +64,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -88,8 +82,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -108,8 +100,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -128,8 +118,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -148,8 +136,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -168,8 +154,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -188,8 +172,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -208,8 +190,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -228,8 +208,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -248,8 +226,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -268,8 +244,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -288,8 +262,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -308,8 +280,6 @@ services:
- %tables.notification_types%
- %tables.notifications%
- %tables.user_notifications%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.type }
@@ -325,8 +295,6 @@ services:
- @config
- %core.root_path%
- %core.php_ext%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.method }
@@ -342,7 +310,5 @@ services:
- @config
- %core.root_path%
- %core.php_ext%
- calls:
- - [set_notification_manager, [@notification_manager]]
tags:
- { name: notification.method }
diff --git a/phpBB/includes/notification/manager.php b/phpBB/includes/notification/manager.php
index a289ec0dfa..5c1016335a 100644
--- a/phpBB/includes/notification/manager.php
+++ b/phpBB/includes/notification/manager.php
@@ -841,6 +841,13 @@ class phpbb_notification_manager
*/
protected function load_object($object_name)
{
- return $this->phpbb_container->get($object_name);
+ $object = $this->phpbb_container->get($object_name);
+
+ if (method_exists($object, 'set_notification_manager'))
+ {
+ $object->set_notification_manager($this);
+ }
+
+ return $object;
}
}