Merge pull request #1953 from CachetHQ/fix-setup

fix setup env writing
This commit is contained in:
James Brooks
2016-07-11 19:03:48 +01:00
committed by GitHub

View File

@@ -250,10 +250,11 @@ class SetupController extends Controller
try {
(new Dotenv($dir, $file))->load();
$envValue = env(strtoupper($key)) ?: 'null';
$envKey = strtoupper($key);
$envValue = env($envKey) ?: 'null';
file_put_contents($path, str_replace(
$envValue, $value, file_get_contents($path)
$envKey.'='.$envValue, $envKey.'='.$value, file_get_contents($path)
));
} catch (InvalidPathException $e) {
//