Skip to content

Commit 6be314d

Browse files
authored
Replace pathInfo by resource variable if path start by static/
1 parent 2de8ccf commit 6be314d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

ObjectManager/BootstrapPool.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,10 @@ public function __construct()
3535
*/
3636
public function get(): AppBootstrap
3737
{
38-
$pathInfo = $_GET['resource'] ?? $_SERVER['REQUEST_URI'];
38+
$pathInfo = $_SERVER['REQUEST_URI'];
39+
if (str_starts_with(trim($pathInfo, '/') . '/', 'static/')) {
40+
$pathInfo = $_GET['resource'] ?? $pathInfo;
41+
}
3942
$areaCode = $this->areaList->getCodeByFrontName(strtok(trim($pathInfo, '/'), '/'));
4043

4144
return $this->bootstraps[$areaCode] ??= $this->createBootstrap($areaCode);

0 commit comments

Comments
 (0)