mirror of
https://github.com/strapi/strapi.git
synced 2026-01-08 21:35:41 +00:00
remove filter on providers response
This commit is contained in:
parent
265ee979e4
commit
e7a4f7f7fa
@ -3,15 +3,9 @@ import axios from 'axios';
|
||||
const MARKETPLACE_API_URL = 'https://market-api.strapi.io';
|
||||
|
||||
const fetchMarketplacePlugins = async () => {
|
||||
const { data: response } = await axios.get(`${MARKETPLACE_API_URL}/providers`);
|
||||
const { data } = await axios.get(`${MARKETPLACE_API_URL}/providers`);
|
||||
|
||||
// Only keep v4 plugins
|
||||
const filteredResponse = {
|
||||
...response,
|
||||
data: response.data.filter((provider) => provider.attributes.strapiCompatibility === 'v4'),
|
||||
};
|
||||
|
||||
return filteredResponse;
|
||||
return data;
|
||||
};
|
||||
|
||||
export { fetchMarketplacePlugins };
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user