You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$messageClassLocation = isset($tag['handles']) ? 'declared in your tag attribute "handles"' : $r->implementsInterface(MessageSubscriberInterface::class) ? sprintf('returned by method "%s::getHandledMessages()"', $r->getName()) : sprintf('used as argument type in method "%s::%s()"', $r->getName(), $method);
121
+
122
+
thrownewRuntimeException(sprintf('Invalid configuration %s for message "%s": bus "%s" does not exist.', $messageClassLocation, $messageClass, $method['bus']));
123
+
}
124
+
125
+
$buses = array($method['bus']);
126
+
}
127
+
128
+
if (isset($method['priority'])) {
129
+
$messagePriority = $method['priority'];
130
+
}
131
+
132
+
$method = $method['method'] ?? '__invoke';
133
+
} else {
134
+
$messageClassLocation = isset($tag['handles']) ? 'declared in your tag attribute "handles"' : $r->implementsInterface(MessageSubscriberInterface::class) ? sprintf('returned by method "%s::getHandledMessages()"', $r->getName()) : sprintf('used as argument type in method "%s::%s()"', $r->getName(), $method);
135
+
136
+
thrownewRuntimeException(sprintf('Invalid configuration %s for message "%s".', $messageClassLocation, $messageClass));
137
+
}
115
138
}
116
139
117
140
if (!\class_exists($messageClass)) {
@@ -132,7 +155,7 @@ private function registerHandlers(ContainerBuilder $container, array $busIds)
* @expectedExceptionMessage Invalid configuration returned by method "Symfony\Component\Messenger\Tests\DependencyInjection\HandlerOnUndefinedBus::getHandledMessages()" for message "Symfony\Component\Messenger\Tests\Fixtures\DummyMessage": bus "some_undefined_bus" does not exist.
0 commit comments