Skip to content

Commit

Permalink
Fix issue if default site is not IDP.
Browse files Browse the repository at this point in the history
  • Loading branch information
cato-cit committed Mar 26, 2020
1 parent 89be9d0 commit 6244810
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions lib/DrupalHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,7 @@ class DrupalHelper
public function bootDrupal($drupalRoot)
{
$autoloader = require_once $drupalRoot . '/autoload.php';
// Inherit the current request's HTTP host to respect trusted hosts
// settings.
$current_request = Request::createFromGlobals();
$server = [
'HTTP_HOST' => $current_request->getHost(),
];
$request = new Request([], [], [], [], [], $server);
$request = Request::createFromGlobals();
$originalDir = getcwd();
chdir($drupalRoot);
$kernel = DrupalKernel::createFromRequest($request, $autoloader, 'prod', true, $drupalRoot);
Expand Down

0 comments on commit 6244810

Please sign in to comment.