Skip to content

Commit 2e61681

Browse files
joachim-nweitzman
authored andcommitted
Removed $_SERVER['HTTP_ACCEPT'] value. (#6599)
1 parent 4273e86 commit 2e61681

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎src/Boot/DrupalBoot8.php‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,11 @@ public function bootstrapDrupalSiteValidate(BootstrapManager $manager): bool
107107
] + $_SERVER;
108108
$request = Request::create($uri, 'GET', [], [], [], $server);
109109
$request->overrideGlobals();
110+
111+
// Remove HTTP_ACCEPT, as things such as the Symfony var-dumper will
112+
// incorrectly sniff that we're in a browser request.
113+
unset($_SERVER['HTTP_ACCEPT']);
114+
110115
$this->setRequest($request);
111116
return true;
112117
}

0 commit comments

Comments
 (0)