Skip to content

Commit 8af727d

Browse files
author
Dominic
committed
Remove direct server variable use
1 parent 8dfe26a commit 8af727d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

app/code/Magento/Store/Model/Store.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -707,7 +707,8 @@ protected function _updatePathUseRewrites($url)
707707
if ($this->_isCustomEntryPoint()) {
708708
$indexFileName = 'index.php';
709709
} else {
710-
$indexFileName = basename($_SERVER['SCRIPT_FILENAME']);
710+
$scriptFilename = $this->_request->getServer('SCRIPT_FILENAME');
711+
$indexFileName = basename($scriptFilename);
711712
}
712713
$url .= $indexFileName . '/';
713714
}

0 commit comments

Comments
 (0)