File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ public function enterNode(Node $node)
5151
5252 if ($ node instanceof Node \Stmt \UseUse) {
5353 $ key = isset ($ node ->alias ) ? $ node ->alias : $ node ->name ->parts [count ($ node ->name ->parts ) - 1 ];
54- $ this ->useStatements [$ key ] = implode ('\\' , $ node ->name ->parts );
54+ $ this ->useStatements [( string ) $ key ] = implode ('\\' , $ node ->name ->parts );
5555
5656 return ;
5757 }
Original file line number Diff line number Diff line change @@ -34,11 +34,11 @@ abstract class AbstractFormType extends BasePHPVisitor implements NodeVisitor
3434 public function enterNode (Node $ node )
3535 {
3636 if ($ node instanceof Node \Expr \MethodCall) {
37- if (!is_string ($ node ->name )) {
37+ if (!is_string ($ node ->name ) && ! $ node -> name instanceof Node \Identifier ) {
3838 return ;
3939 }
4040
41- $ name = strtolower ($ node ->name );
41+ $ name = strtolower (( string ) $ node ->name );
4242 if ('setdefaults ' === $ name || 'replacedefaults ' === $ name || 'setdefault ' === $ name ) {
4343 $ this ->parseDefaultsCall ($ node );
4444
You can’t perform that action at this time.
0 commit comments