Skip to content

Instantly share code, notes, and snippets.

@imcbride
Created August 25, 2021 20:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save imcbride/efff6c68ddd611c5c7f72c2c5bd67668 to your computer and use it in GitHub Desktop.
Save imcbride/efff6c68ddd611c5c7f72c2c5bd67668 to your computer and use it in GitHub Desktop.
diff --git a/src/Utils/DrupalApi.php b/src/Utils/DrupalApi.php
index 57a97d1a5..f39308be8 100644
--- a/src/Utils/DrupalApi.php
+++ b/src/Utils/DrupalApi.php
@@ -263,7 +263,8 @@ public function drupal_rebuild($class_loader, \Symfony\Component\HttpFoundation\
$kernel->invalidateContainer();
// Prepare a NULL request.
- $kernel->prepareLegacyRequest($request);
+ $kernel->boot();
+ $kernel->preHandle($request);
foreach (Cache::getBins() as $bin) {
$bin->deleteAll();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment