Skip to content

Commit efb6127

Browse files
committed
Readability improvements
1 parent 25d0db9 commit efb6127

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

lib/internal/Magento/Framework/Interception/Code/InterfaceValidator.php

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -65,12 +65,6 @@ public function validate($pluginClass, $interceptedType)
6565
)
6666
);
6767
}
68-
$originMethod = $type->getMethod($originMethodName);
69-
70-
$pluginMethodParameters = $this->getMethodParameters($pluginMethod);
71-
$originMethodParameters = $this->getMethodParameters($originMethod);
72-
73-
$methodType = $this->getMethodType($pluginMethod->getName());
7468

7569
$subject = array_shift($pluginMethodParameters);
7670
if ($subject['type'] === null
@@ -83,6 +77,11 @@ public function validate($pluginClass, $interceptedType)
8377
);
8478
}
8579

80+
$originMethod = $type->getMethod($originMethodName);
81+
$originMethodParameters = $this->getMethodParameters($originMethod);
82+
$pluginMethodParameters = $this->getMethodParameters($pluginMethod);
83+
$methodType = $this->getMethodType($pluginMethod->getName());
84+
8685
if (self::METHOD_AFTER === $methodType && count($pluginMethodParameters) > 1) {
8786
// remove result
8887
array_shift($pluginMethodParameters);

0 commit comments

Comments
 (0)