mirror of
https://github.com/strapi/strapi.git
synced 2025-10-24 14:29:58 +00:00
Merge branch 'releases/v4' into v4/middlewares
This commit is contained in:
commit
e47f5cb5fc
@ -127,7 +127,11 @@ const createContentType = async ({ contentType, components = [] }, options = {})
|
||||
*/
|
||||
const generateAPI = ({ name, kind = 'collectionType' }) => {
|
||||
const strapiGenerators = require('@strapi/generators');
|
||||
return strapiGenerators.generate('api', { id: nameToSlug(name), kind }, { dir: strapi.dirs.src });
|
||||
return strapiGenerators.generate(
|
||||
'api',
|
||||
{ id: nameToSlug(name), kind },
|
||||
{ dir: strapi.dirs.root }
|
||||
);
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
@ -4,4 +4,4 @@
|
||||
* {{id}} service.
|
||||
*/
|
||||
|
||||
module.exports = {};
|
||||
module.exports = () => ({});
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user