Jamie Howard e5d4b412da
Fix plugin content-api route extensions (#24147)
* fix: content-api route extension for i18n and users-permissions

* refactor: simplify tests to catch breaking change

* test: cli for openapi plugin routes

* refactor: implement createcontentapiroutesfactory for content-api routes across multiple packages

* fix: more accurate message

* chore: formatting

* chore: cleanup backward compatibility tests

---------

Co-authored-by: Ziyi Yuan <daydreamnation@live.com>
2025-08-18 12:28:39 +01:00

19 lines
496 B
JavaScript

'use strict';
const { createContentApiRoutesFactory } = require('@strapi/utils');
const authRoutes = require('./auth');
const userRoutes = require('./user');
const roleRoutes = require('./role');
const permissionsRoutes = require('./permissions');
const createContentApiRoutes = createContentApiRoutesFactory(() => {
return [
...authRoutes(strapi),
...userRoutes(strapi),
...roleRoutes(strapi),
...permissionsRoutes(strapi),
];
});
module.exports = createContentApiRoutes;