Skip to content
Snippets Groups Projects
Commit 7f210b05 authored by Daniel Kurowski's avatar Daniel Kurowski
Browse files

KeepMethodDecorator: import FQN of interfaces as well

parent 519d5345
No related merge requests found
Pipeline #31621 passed
...@@ -79,7 +79,7 @@ final class KeepMethodDecorator implements ClassDecorator ...@@ -79,7 +79,7 @@ final class KeepMethodDecorator implements ClassDecorator
*/ */
foreach ($method->getParameters() as $parameter) { foreach ($method->getParameters() as $parameter) {
$type = $parameter->getType(); $type = $parameter->getType();
if ($type !== null && \class_exists($type)) { if ($type !== null && (\class_exists($type) || \interface_exists($type))) {
$namespace->addUse($type); $namespace->addUse($type);
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment