File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 44
55namespace Rector \Privatization \Rector \ClassMethod ;
66
7+ use Rector \Privatization \VisibilityGuard \ParentClassMagicCallGuard ;
78use PhpParser \Node ;
89use PhpParser \Node \Expr \StaticCall ;
910use PhpParser \Node \Stmt \Class_ ;
@@ -30,7 +31,7 @@ public function __construct(
3031 private readonly OverrideByParentClassGuard $ overrideByParentClassGuard ,
3132 private readonly BetterNodeFinder $ betterNodeFinder ,
3233 private readonly LaravelModelGuard $ laravelModelGuard ,
33- private readonly \ Rector \ Privatization \ VisibilityGuard \ ParentClassMagicCallGuard $ parentClassMagicCallGuard
34+ private readonly ParentClassMagicCallGuard $ parentClassMagicCallGuard
3435 ) {
3536 }
3637
Original file line number Diff line number Diff line change 44
55namespace Rector \Privatization \VisibilityGuard ;
66
7+ use PhpParser \Node \Name ;
78use PhpParser \Node \Expr ;
89use PhpParser \Node \Expr \MethodCall ;
910use PhpParser \Node \Stmt \Class_ ;
@@ -37,7 +38,7 @@ public function containsParentClassMagicCall(Class_ $class): bool
3738 return $ this ->cachedContainsByClassName [$ className ];
3839 }
3940
40- if ($ class ->extends === null ) {
41+ if (! $ class ->extends instanceof Name ) {
4142 return false ;
4243 }
4344
You can’t perform that action at this time.
0 commit comments