Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
'services/*': cb => {
dictionary.optional({
dirname: path.resolve(strapi.config.appPath, strapi.config.paths.api, api, strapi.config.paths.services),
filter: /(.+)\.(js)$/,
depth: 1
}, cb);
},
'api/**': cb => {
dictionary.optional(
{
dirname: path.resolve(
strapi.config.appPath,
strapi.config.paths.api
),
excludeDirs: /(public)$/,
filter: /(.+)\.(js|json)$/,
depth: 3
},
cb
);
},
externalHooks: cb => {
dictionary.optional({
dirname: path.resolve(strapi.config.appPath, 'node_modules'),
filter: /^(package\.json)$/,
excludeDirs: /^((?!(strapi-)).)*$/,
depth: 2
}, cb);
}
},
'controllers/*': cb => {
dictionary.optional({
dirname: path.resolve(strapi.config.appPath, strapi.config.paths.plugins, plugin, strapi.config.paths.controllers),
filter: /(.+)\.(js)$/,
depth: 1
}, cb);
},
'services/*': cb => {
dictionary.optional({
dirname: path.resolve(strapi.config.appPath, strapi.config.paths.admin, strapi.config.paths.services),
filter: /(.+)\.(js)$/,
depth: 1
}, cb);
},