aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/di/pass/collection_pass.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/phpbb/di/pass/collection_pass.php')
-rw-r--r--phpBB/phpbb/di/pass/collection_pass.php11
1 files changed, 10 insertions, 1 deletions
diff --git a/phpBB/phpbb/di/pass/collection_pass.php b/phpBB/phpbb/di/pass/collection_pass.php
index a5c054674e..ccc1250c20 100644
--- a/phpBB/phpbb/di/pass/collection_pass.php
+++ b/phpBB/phpbb/di/pass/collection_pass.php
@@ -37,7 +37,16 @@ class collection_pass implements CompilerPassInterface
foreach ($container->findTaggedServiceIds($data[0]['tag']) as $service_id => $service_data)
{
- $definition->addMethodCall('add', array($service_id));
+ if (substr($definition->getClass(), -strlen('ordered_service_collection')) === 'ordered_service_collection')
+ {
+ $arguments = array($service_id, $service_data[0]['order']);
+ }
+ else
+ {
+ $arguments = array($service_id);
+ }
+
+ $definition->addMethodCall('add', $arguments);
}
}
}