File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 6
6
use Illuminate \Console \Command ;
7
7
use Illuminate \Contracts \Config \Repository ;
8
8
use Illuminate \Foundation \Http \FormRequest ;
9
+ use Illuminate \Routing \RouteAction ;
9
10
use Illuminate \Routing \Router ;
10
11
use Illuminate \Support \Facades \Storage ;
11
12
use Illuminate \Support \Str ;
@@ -140,6 +141,11 @@ public function handle(): void
140
141
141
142
protected function getReflectionMethod (array $ routeAction ): ?object
142
143
{
144
+ // Hydrates the closure if it is an instance of Opis\Closure\SerializableClosure
145
+ if (RouteAction::containsSerializedClosure ($ routeAction )) {
146
+ $ routeAction ['uses ' ] = unserialize ($ routeAction ['uses ' ])->getClosure ();
147
+ }
148
+
143
149
if ($ routeAction ['uses ' ] instanceof Closure) {
144
150
return new ReflectionFunction ($ routeAction ['uses ' ]);
145
151
}
You can’t perform that action at this time.
0 commit comments