Skip to content

Commit 91d72a6

Browse files
author
Kevin Grenier
committed
Removed dead code in Kernel
1 parent f0168e3 commit 91d72a6

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

src/Symfony/Component/HttpKernel/Kernel.php

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -244,19 +244,10 @@ public function locateResource($name, $dir = null, $first = true)
244244

245245
$isResource = 0 === strpos($path, 'Resources') && null !== $dir;
246246
$overridePath = substr($path, 9);
247-
$resourceBundle = null;
248247
$bundle = $this->getBundle($bundleName);
249248
$files = array();
250249

251250
if ($isResource && file_exists($file = $dir.'/'.$bundle->getName().$overridePath)) {
252-
if (null !== $resourceBundle) {
253-
throw new \RuntimeException(sprintf('"%s" resource is hidden by a resource from the "%s" derived bundle. Create a "%s" file to override the bundle resource.',
254-
$file,
255-
$resourceBundle,
256-
$dir.'/'.$bundle->getName().$overridePath
257-
));
258-
}
259-
260251
$files[] = $file;
261252
}
262253

@@ -265,7 +256,6 @@ public function locateResource($name, $dir = null, $first = true)
265256
return $file;
266257
}
267258
$files[] = $file;
268-
$resourceBundle = $bundle->getName();
269259
}
270260

271261
if (\count($files) > 0) {

0 commit comments

Comments
 (0)