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
Copy file name to clipboardExpand all lines: LazyProxy/PhpDumper/LazyServiceDumper.php
+4-3Lines changed: 4 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -123,12 +123,13 @@ public function getProxyCode(Definition $definition, string $id = null): string
123
123
if (!interface_exists($tag['interface']) && !class_exists($tag['interface'], false)) {
124
124
thrownewInvalidArgumentException(sprintf('Invalid definition for service "%s": several "proxy" tags found but "%s" is not an interface.', $id ?? $definition->getClass(), $tag['interface']));
125
125
}
126
+
if (!is_a($class->name, $tag['interface'], true)) {
127
+
thrownewInvalidArgumentException(sprintf('Invalid "proxy" tag for service "%s": class "%s" doesn\'t implement "%s".', $id ?? $definition->getClass(), $definition->getClass(), $tag['interface']));
128
+
}
126
129
$interfaces[] = new \ReflectionClass($tag['interface']);
127
130
}
128
131
129
-
if (1 === \count($interfaces) && !$interfaces[0]->isInterface()) {
0 commit comments