mirror of
https://github.com/rectorphp/rector.git
synced 2024-06-27 13:13:31 +00:00
skip missing scope
This commit is contained in:
parent
1abe1f8c1b
commit
6e955b9d80
|
@ -109,8 +109,10 @@ CODE_SAMPLE
|
|||
|
||||
private function shouldSkip(ClassMethod $classMethod): bool
|
||||
{
|
||||
/** @var Scope $scope */
|
||||
$scope = $classMethod->getAttribute(AttributeKey::SCOPE);
|
||||
if (! $scope instanceof Scope) {
|
||||
return true;
|
||||
}
|
||||
|
||||
// catch only classes without namespace
|
||||
if ($scope->getNamespace() !== null) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user