From 31a731deb7cc65e303d92e82d77ddad8265bbad2 Mon Sep 17 00:00:00 2001 From: Art4 Date: Mon, 23 Dec 2024 14:23:58 +0000 Subject: [PATCH] Refactor dependency for $_COOKIE --- static/dependencies.config.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/static/dependencies.config.php b/static/dependencies.config.php index 67c7194c30..1ead393f48 100644 --- a/static/dependencies.config.php +++ b/static/dependencies.config.php @@ -39,7 +39,7 @@ use Friendica\Util; /** * @param string $basepath The base path of the Friendica installation without trailing slash */ -return (function(string $basepath, array $getVars, array $serverVars): array { +return (function(string $basepath, array $getVars, array $serverVars, array $cookieVars): array { return [ '*' => [ // marks all class result as shared for other creations, so there's just @@ -257,7 +257,7 @@ return (function(string $basepath, array $getVars, array $serverVars): array { ], Cookie::class => [ 'constructParams' => [ - $_COOKIE + $cookieVars, ], ], ICanWriteToStorage::class => [ @@ -311,5 +311,6 @@ return (function(string $basepath, array $getVars, array $serverVars): array { })( dirname(__FILE__, 2), $_GET, - $_SERVER + $_SERVER, + $_COOKIE );