Skip to content

Commit 1e5d611

Browse files
committed
Merge branch 'ACP2E-3681' of https://github.com/adobe-commerce-tier-4/magento2ce into PR-Tier4-VK-2025-02-14
2 parents 96dec49 + 3bd9444 commit 1e5d611

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

lib/internal/Magento/Framework/App/DeploymentConfig.php

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
<?php
22
/**
3-
* Copyright © Magento, Inc. All rights reserved.
4-
* See COPYING.txt for license details.
3+
* Copyright 2014 Adobe
4+
* All Rights Reserved.
55
*/
6-
76
namespace Magento\Framework\App;
87

98
use Magento\Framework\Config\ConfigOptionsListConstants;
@@ -226,7 +225,11 @@ private function getAllEnvOverrides(): array
226225
) {
227226
// convert MAGENTO_DC_DB__CONNECTION__DEFAULT__HOST into db/connection/default/host
228227
$flatKey = strtolower(str_replace([self::MAGENTO_ENV_PREFIX, '__'], ['', '/'], $key));
229-
$this->envOverrides[$flatKey] = $value;
228+
$this->envOverrides[$flatKey] = match ($value) {
229+
'true', 'TRUE' => true,
230+
'false', 'FALSE' => false,
231+
default => $value,
232+
};
230233
}
231234
}
232235
}

lib/internal/Magento/Framework/App/Test/Unit/DeploymentConfigTest.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
<?php
2-
32
/**
4-
* Copyright © Magento, Inc. All rights reserved.
5-
* See COPYING.txt for license details.
3+
* Copyright 2014 Adobe
4+
* All Rights Reserved.
65
*/
7-
86
declare(strict_types=1);
97

108
namespace Magento\Framework\App\Test\Unit;
@@ -279,8 +277,10 @@ public function testEnvVariablesWithNoBaseConfig(): void
279277
$this->readerMock->expects($this->once())->method('load')->willReturn(['a'=>'b']);
280278
putenv('MAGENTO_DC_A=c');
281279
putenv('MAGENTO_DC_B__B__B=D');
280+
putenv('MAGENTO_DC_C=false');
282281
$this->assertSame('c', $this->deploymentConfig->get('a'));
283282
$this->assertSame('D', $this->deploymentConfig->get('b/b/b'));
283+
$this->assertFalse($this->deploymentConfig->get('c'));
284284
}
285285

286286
public function testEnvVariablesSubstitution(): void

0 commit comments

Comments
 (0)