File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -74,12 +74,13 @@ public function getControllersInfo(): array
74
74
}
75
75
76
76
try {
77
+ $ actionControllerName = $ route ->action ['controller ' ] ?? $ route ->action ["0 " ];
77
78
/// Show Pnly Controller Name
78
- $ controllerFullPath = explode ('@ ' , $ route -> action [ ' controller ' ] )[0 ];
79
- $ getStartWord = strrpos (explode ('@ ' , $ route -> action [ ' controller ' ] )[0 ], '\\' ) + 1 ;
79
+ $ controllerFullPath = explode ('@ ' , $ actionControllerName )[0 ];
80
+ $ getStartWord = strrpos (explode ('@ ' , $ actionControllerName )[0 ], '\\' ) + 1 ;
80
81
$ controllerName = substr ($ controllerFullPath , $ getStartWord );
81
82
82
- $ method = explode ('@ ' , $ route -> action [ ' controller ' ] )[1 ];
83
+ $ method = explode ('@ ' , $ actionControllerName )[1 ] ?? ' __invoke ' ;
83
84
$ httpMethod = $ route ->methods [0 ];
84
85
foreach ($ controllersInfo as $ controllerInfo ) {
85
86
if ($ controllerInfo ['uri ' ] == $ route ->uri && $ controllerInfo ['httpMethod ' ] == $ httpMethod ) {
You can’t perform that action at this time.
0 commit comments