From 25e0965590ca437aa46e93bbf4af1f17c88d9021 Mon Sep 17 00:00:00 2001 From: Okabe Rintaro Date: Tue, 18 Oct 2022 16:17:10 +0300 Subject: [PATCH] fix update env php removing pq config --- .../lib/tasks/php/update-env-php.js | 20 ++----------------- 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/build-packages/magento-scripts/lib/tasks/php/update-env-php.js b/build-packages/magento-scripts/lib/tasks/php/update-env-php.js index f4b83b76..2d4edfdd 100644 --- a/build-packages/magento-scripts/lib/tasks/php/update-env-php.js +++ b/build-packages/magento-scripts/lib/tasks/php/update-env-php.js @@ -1,6 +1,5 @@ const path = require('path'); const os = require('os'); -const envPhpToJson = require('../../util/env-php-json'); const getJsonfileData = require('../../util/get-jsonfile-data'); const pathExists = require('../../util/path-exists'); const { containerApi } = require('../docker/containers'); @@ -36,23 +35,8 @@ const updateEnvPHP = () => ({ if (await pathExists(composerLockPath)) { const composerLockData = await getJsonfileData(composerLockPath); - if (composerLockData.packages.some(({ name }) => name === 'scandipwa/persisted-query')) { - if (typeof ctx.CSAThemeInstalled !== 'boolean') { - ctx.CSAThemeInstalled = true; - } - - const envPhp = await envPhpToJson(ctx); - - const persistedQueryConfig = envPhp.cache && envPhp.cache['persisted-query']; - - if ( - persistedQueryConfig - && persistedQueryConfig.redis - && (persistedQueryConfig.redis.port !== `${ ctx.ports.redis }` - || persistedQueryConfig.redis.host === hostMachine) - ) { - SETUP_PQ = ''; - } + if (!composerLockData.packages.some(({ name }) => name === 'scandipwa/persisted-query')) { + SETUP_PQ = ''; } }