Skip to content

Commit a81ac18

Browse files
committed
fix(studio): invalid auth
1 parent fa32fc6 commit a81ac18

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

src/app.module.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,11 @@ export class AppModule implements NestModule {
5454
private readonly logger = new Logger(AppModule.name);
5555
configure(consumer: MiddlewareConsumer) {
5656
consumer.apply(AuthMiddleware).forRoutes(
57-
...['movie', 'season', 'person', 'review', 'image', 'keyword'].map((name) => ({
57+
...['movie', 'season', 'person', 'review', 'image', 'keyword', 'studio'].map((name) => ({
5858
path: `/v1/${name}`,
5959
method: RequestMethod.GET,
6060
})),
61-
...['movie', 'season', 'person', 'review', 'image', 'keyword'].map((name) => ({
61+
...['movie', 'season', 'person', 'review', 'image', 'keyword', 'studio'].map((name) => ({
6262
path: `/v1.1/${name}`,
6363
method: RequestMethod.GET,
6464
})),

src/common/decorators/paginated.decorator.ts

+9
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,15 @@ const entitiesField: Entities = {
195195
dateSearchKeys: [],
196196
numberSearchKeys: ['id', 'movies.id'],
197197
},
198+
studio: {
199+
excludedValuesFields: [],
200+
blacklistFields: ['-_id'],
201+
allowFieldsFindAll: [],
202+
idKeys: ['movies.id', 'id'],
203+
regexSearchKeys: ['title'],
204+
dateSearchKeys: [],
205+
numberSearchKeys: ['id', 'movies.id'],
206+
},
198207
};
199208

200209
export const Paginated = (

0 commit comments

Comments
 (0)