File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -135,9 +135,7 @@ public static function registry()
135
135
*/
136
136
protected static function _buildEngine ($ name )
137
137
{
138
- if (empty (static ::$ _registry )) {
139
- static ::$ _registry = new CacheRegistry ();
140
- }
138
+ $ registry = static ::registry ();
141
139
142
140
if (empty (static ::$ _config [$ name ]['className ' ])) {
143
141
throw new InvalidArgumentException (
@@ -146,7 +144,7 @@ protected static function _buildEngine($name)
146
144
}
147
145
148
146
$ config = static ::$ _config [$ name ];
149
- static :: $ _registry ->load ($ name , $ config );
147
+ $ registry ->load ($ name , $ config );
150
148
151
149
if (!empty ($ config ['groups ' ])) {
152
150
foreach ($ config ['groups ' ] as $ group ) {
@@ -172,12 +170,14 @@ public static function engine($config)
172
170
return new NullEngine ();
173
171
}
174
172
175
- if (isset (static ::$ _registry ->{$ config })) {
176
- return static ::$ _registry ->{$ config };
173
+ $ registry = static ::registry ();
174
+
175
+ if (isset ($ registry ->{$ config })) {
176
+ return $ registry ->{$ config };
177
177
}
178
178
179
179
static ::_buildEngine ($ config );
180
- return static :: $ _registry ->{$ config };
180
+ return $ registry ->{$ config };
181
181
}
182
182
183
183
/**
You can’t perform that action at this time.
0 commit comments