From ef1ec46bad52cef3ca28757d2665721cf01e6d16 Mon Sep 17 00:00:00 2001 From: Jens Date: Thu, 30 Mar 2023 10:32:31 +0200 Subject: [PATCH] (Refactor) Remove getEnvironmentValue, rename setEnvironmentValue to setenv to match php defaults --- public/install/functions.php | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/public/install/functions.php b/public/install/functions.php index 032901ed..f10c02a8 100644 --- a/public/install/functions.php +++ b/public/install/functions.php @@ -129,22 +129,12 @@ function checkExtensions(): array * @param string $envValue The environment variable to set * @return bool true on success or false on failure. */ -function setEnvironmentValue(string $envKey, $envValue) +function setenv(string $envKey, $envValue) { $str = "{$envKey}={$envValue}"; return putenv($str); } -/** - * Gets the variable from the env file - * @param string $envKey The environment variable to look for - * @return array|false|string Returns the value if found, otherwise returns false. - */ -function getEnvironmentValue(string $envKey): array|false|string -{ - return getenv($envKey); -} - /** * Encrypt the given value