@@ -123,7 +123,7 @@ private function parseImports(\DOMDocument $xml, string $file, ?\DOMNode $root =
123123 $ xpath = new \DOMXPath ($ xml );
124124 $ xpath ->registerNamespace ('container ' , self ::NS );
125125
126- if (false === $ imports = $ xpath ->query ('.// container:imports/container:import ' , $ root )) {
126+ if (false === $ imports = $ xpath ->query ('./container:imports/container:import ' , $ root )) {
127127 return ;
128128 }
129129
@@ -139,14 +139,14 @@ private function parseDefinitions(\DOMDocument $xml, string $file, Definition $d
139139 $ xpath = new \DOMXPath ($ xml );
140140 $ xpath ->registerNamespace ('container ' , self ::NS );
141141
142- if (false === $ services = $ xpath ->query ('.// container:services/container:service|.// container:services/container:prototype|./ /container:services/container:stack ' , $ root )) {
142+ if (false === $ services = $ xpath ->query ('./container:services/container:service|./container:services/container:prototype|./container:services/container:stack ' , $ root )) {
143143 return ;
144144 }
145145 $ this ->setCurrentDir (\dirname ($ file ));
146146
147147 $ this ->instanceof = [];
148148 $ this ->isLoadingInstanceof = true ;
149- $ instanceof = $ xpath ->query ('.// container:services/container:instanceof ' , $ root );
149+ $ instanceof = $ xpath ->query ('./container:services/container:instanceof ' , $ root );
150150 foreach ($ instanceof as $ service ) {
151151 $ this ->setDefinition ((string ) $ service ->getAttribute ('id ' ), $ this ->parseDefinition ($ service , $ file , new Definition ()));
152152 }
@@ -197,7 +197,7 @@ private function getServiceDefaults(\DOMDocument $xml, string $file, ?\DOMNode $
197197 $ xpath = new \DOMXPath ($ xml );
198198 $ xpath ->registerNamespace ('container ' , self ::NS );
199199
200- if (null === $ defaultsNode = $ xpath ->query ('.// container:services/container:defaults ' , $ root )->item (0 )) {
200+ if (null === $ defaultsNode = $ xpath ->query ('./container:services/container:defaults ' , $ root )->item (0 )) {
201201 return new Definition ();
202202 }
203203
0 commit comments