From 36b2b55e572e000f45e577b4d308e82a4b7479ed Mon Sep 17 00:00:00 2001 From: Sorin Sarca Date: Sat, 5 Sep 2020 17:40:44 +0300 Subject: [PATCH] Fixes #78 --- src/ReflectionClosure.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ReflectionClosure.php b/src/ReflectionClosure.php index 204b13b..82fe7d6 100644 --- a/src/ReflectionClosure.php +++ b/src/ReflectionClosure.php @@ -521,6 +521,10 @@ public function getCode() } if(isset($functions[$id_start_ci])){ $id_start = $functions[$id_start_ci]; + } elseif ($nsf !== '\\' && function_exists($nsf . '\\' . $id_start)) { + $id_start = $nsf . '\\' . $id_start; + // Cache it to functions array + $functions[$id_start_ci] = $id_start; } } }