Skip to content

Commit

Permalink
OXDEV-7822 Use multishop context in yaml validator
Browse files Browse the repository at this point in the history
  • Loading branch information
Sieg committed Mar 27, 2024
1 parent 1039f3e commit 42d98d3
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,16 @@
use OxidEsales\EshopCommunity\Internal\Framework\DIContainer\ContainerBuilder;
use OxidEsales\EshopCommunity\Internal\Framework\DIContainer\Dao\ProjectYamlDaoInterface;
use OxidEsales\EshopCommunity\Internal\Framework\DIContainer\Exception\NoServiceYamlException;
use OxidEsales\EshopCommunity\Internal\Framework\Module\Configuration\DataObject\ModuleConfiguration;
use OxidEsales\EshopCommunity\Internal\Framework\Module\Path\ModulePathResolverInterface;
use OxidEsales\EshopCommunity\Internal\Framework\Module\Setup\Exception\InvalidModuleServicesException;
use OxidEsales\EshopCommunity\Internal\Transition\Utility\BasicContextInterface;
use OxidEsales\EshopCommunity\Internal\Framework\Module\Configuration\DataObject\ModuleConfiguration;
use OxidEsales\EshopCommunity\Internal\Transition\Utility\ContextInterface;
use Symfony\Component\Filesystem\Path;

class ServicesYamlValidator implements ModuleConfigurationValidatorInterface
{
public function __construct(
private BasicContextInterface $basicContext,
private ContextInterface $context,
private ProjectYamlDaoInterface $projectYamlDao,
private ModulePathResolverInterface $modulePathResolver
) {
Expand Down Expand Up @@ -68,7 +68,7 @@ public function validate(ModuleConfiguration $configuration, int $shopId): void
*/
private function buildContainer(): \Symfony\Component\DependencyInjection\ContainerBuilder
{
$containerBuilder = new ContainerBuilder($this->basicContext);
$containerBuilder = new ContainerBuilder($this->context);
$container = $containerBuilder->getContainer();
foreach ($container->getDefinitions() as $definition) {
$definition->setPublic(true);
Expand Down

0 comments on commit 42d98d3

Please sign in to comment.