Hardcode marketplace URL

This commit is contained in:
Rémi de Juvigny 2022-02-17 11:04:45 +01:00
parent 909e2be0ba
commit 53e12d69cd
2 changed files with 3 additions and 5 deletions

View File

@ -1,9 +1,9 @@
import axios from 'axios'; import axios from 'axios';
const MARKETPLACE_API_URL = 'https://market-api.strapi.io';
const fetchPlugins = async notify => { const fetchPlugins = async notify => {
const { data: response } = await axios.get( const { data: response } = await axios.get(`${MARKETPLACE_API_URL}/plugins`);
`${process.env.STRAPI_ADMIN_MARKETPLACE_API_URL}/plugins`
);
// Only keep v4 plugins // Only keep v4 plugins
const filteredResponse = { const filteredResponse = {

View File

@ -25,8 +25,6 @@ const getClientEnvironment = options => {
ADMIN_PATH: options.adminPath, ADMIN_PATH: options.adminPath,
NODE_ENV: options.env || 'development', NODE_ENV: options.env || 'development',
STRAPI_ADMIN_BACKEND_URL: options.backend, STRAPI_ADMIN_BACKEND_URL: options.backend,
STRAPI_ADMIN_MARKETPLACE_API_URL:
process.env.STRAPI_ADMIN_MARKETPLACE_API_URL || 'https://market-api.strapi.io',
} }
); );