File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -163,10 +163,6 @@ public function task(string $name): Task
163163 */
164164 public function getResource (string $ name , bool $ fresh = false ): mixed
165165 {
166- if ($ name === 'utopia ' ) {
167- return $ this ;
168- }
169-
170166 if (!\array_key_exists ($ name , $ this ->resources ) || $ fresh || self ::$ resourcesCallbacks [$ name ]['reset ' ]) {
171167 if (!\array_key_exists ($ name , self ::$ resourcesCallbacks )) {
172168 throw new Exception ('Failed to find resource: " ' . $ name . '" ' );
@@ -213,9 +209,6 @@ public function getResources(array $list): array
213209 */
214210 public static function setResource (string $ name , callable $ callback , array $ injections = []): void
215211 {
216- if ($ name === 'utopia ' ) {
217- throw new Exception ("'utopia' is a reserved keyword. " , 500 );
218- }
219212 self ::$ resourcesCallbacks [$ name ] = ['callback ' => $ callback , 'injections ' => $ injections , 'reset ' => true ];
220213 }
221214
You can’t perform that action at this time.
0 commit comments