Skip to content

Commit

Permalink
[BUGFIX] Handle missing $_SERVER['PATH_INFO']
Browse files Browse the repository at this point in the history
Fix PHP8 warning issue if $_SERVER['PATH_INFO'] is not set.

Resolves: #96373
Releases: main, 11.4
Change-Id: I427aee39c6f6389e418f27474c01cbfd973355e1
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72687
Reviewed-by: Helmut Hummel <typo3@helhum.io>
Tested-by: core-ci <typo3@b13.com>
Tested-by: Helmut Hummel <typo3@helhum.io>
  • Loading branch information
liayn authored and helhum committed Dec 16, 2021
1 parent 20d8dd7 commit 9fbda17
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion typo3/sysext/core/Classes/Utility/GeneralUtility.php
Expand Up @@ -2506,7 +2506,7 @@ public static function getIndpEnv($getEnvName)
// return FALSE for CGI-versions, but that is only as long as SCRIPT_NAME is set equal to PATH_INFO
// because of PHP_SAPI=='cgi' (see above)
if (!Environment::isRunningOnCgiServer()) {
$retVal = $_SERVER['PATH_INFO'];
$retVal = $_SERVER['PATH_INFO'] ?? '';
}
break;
case 'TYPO3_REV_PROXY':
Expand Down

0 comments on commit 9fbda17

Please sign in to comment.