From 1f181c4935d5ae3eccab13886bf5ca5dfa384daf Mon Sep 17 00:00:00 2001 From: "Bruno O. Notario" Date: Tue, 6 Feb 2024 12:24:26 -0300 Subject: [PATCH] Change factory pattern 2 --- system/engine/registry.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/engine/registry.php b/system/engine/registry.php index c61de17..ab25eb9 100644 --- a/system/engine/registry.php +++ b/system/engine/registry.php @@ -345,7 +345,7 @@ final class Registry { if ($injectionClass === self::FACTORY_CLASS) { $declaringClass = $param->__toString(); - $pattern = '/<[^>]+>\s*([^$\s]+)/'; + $pattern = '/\[.*?>\s*([^$\s]+)/';//$pattern = '/<[^>]+>\s*([^$\s]+)/'; if (preg_match($pattern, $declaringClass, $matches)) { $classFactoryName = $matches[1];