From 3fc53b887c42e80e4b503e56ea02cd23ca3362c7 Mon Sep 17 00:00:00 2001 From: "Nathan J. Brauer" Date: Sun, 15 Oct 2023 17:52:47 -0700 Subject: [PATCH] Fixes internal infinite recursion on Nginx/PHP-FPM environments --- src/Controllers/ShareDraftController.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Controllers/ShareDraftController.php b/src/Controllers/ShareDraftController.php index 3ea1914..0e7ac87 100644 --- a/src/Controllers/ShareDraftController.php +++ b/src/Controllers/ShareDraftController.php @@ -175,6 +175,9 @@ private function getRenderedPageByURL(string $url): HTTPResponse ? $variables['_SERVER']['HTTP_USER_AGENT'] : 'CLI'; + // This extra step required for PHP-FPM/Nginx implementations + $variables['env'] = $variables['_SERVER']; + Environment::setVariables($variables); // Health-check prior to creating environment