fix: middleware position

This commit is contained in:
Chareice 2024-01-31 22:21:28 +08:00
parent d694a7b483
commit c6fc1b65b8
No known key found for this signature in database

View File

@ -98,7 +98,7 @@ export function registerMiddlewares(app: Application, options: ApplicationOption
app.use(db2resource, { tag: 'db2resource', after: 'dataWrapping' });
app.use(app.resourcer.restApiMiddleware({ skipIfDataSourceExists: true }), { tag: 'restApi', after: 'db2resource' });
app.use(app.dataSourceManager.middleware(), { tag: 'dataSource', after: 'dataWrapping' });
app.use(app.dataSourceManager.middleware(), { tag: 'dataSource', after: 'restApi' });
}
export const createAppProxy = (app: Application) => {