core: Don't use server variables in CLI mode (#939)

This commit is contained in:
triatic 2018-11-26 17:33:51 +00:00 committed by LogMANOriginal
parent 6e9c188a72
commit 263e8872ea
2 changed files with 7 additions and 4 deletions

View file

@ -77,7 +77,7 @@ function buildBridgeException($e, $bridge){
$body = 'Error message: `'
. $e->getMessage()
. "`\nQuery string: `"
. $_SERVER['QUERY_STRING']
. (isset($_SERVER['QUERY_STRING']) ? $_SERVER['QUERY_STRING'] : '')
. "`\nVersion: `"
. Configuration::getVersion()
. '`';
@ -116,7 +116,8 @@ function buildTransformException($e, $bridge){
$body = 'Error message: `'
. $e->getMessage()
. "`\nQuery string: `"
. $_SERVER['QUERY_STRING'] . '`';
. (isset($_SERVER['QUERY_STRING']) ? $_SERVER['QUERY_STRING'] : '')
. '`';
$link = buildGitHubIssueQuery($title, $body, 'bug report', $bridge->getMaintainer());
$header = buildHeader($e, $bridge);