Skip to content
This repository was archived by the owner on Apr 11, 2024. It is now read-only.

Commit 8872c5c

Browse files
committed
flat qs
1 parent 06cacb5 commit 8872c5c

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/controllers/sessions.ts

+5-5
Original file line numberDiff line numberDiff line change
@@ -57,27 +57,27 @@ export async function GetSessions(req: Request, res: Response) {
5757
},
5858
]
5959
args.where.eventId = {
60-
in: [req.query.event] as string[],
60+
in: [req.query.event].flat() as string[],
6161
}
6262
}
6363
if (req.query.event) {
6464
args.where.eventId = {
65-
in: [req.query.event] as string[],
65+
in: [req.query.event].flat() as string[],
6666
}
6767
}
6868
if (req.query.expertise) {
6969
args.where.expertise = {
70-
in: [req.query.expertise] as string[],
70+
in: [req.query.expertise].flat() as string[],
7171
}
7272
}
7373
if (req.query.type) {
7474
args.where.type = {
75-
in: [req.query.type] as string[],
75+
in: [req.query.type].flat() as string[],
7676
}
7777
}
7878
if (req.query.tags) {
7979
args.where.track = {
80-
in: [req.query.tags] as string[],
80+
in: [req.query.tags].flat() as string[],
8181
}
8282
}
8383

src/controllers/speakers.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ export async function GetSpeakers(req: Request, res: Response) {
2424
// Note: filters are case sensitive
2525
if (req.query.event) {
2626
args.where.eventId = {
27-
in: [req.query.event] as string[],
27+
in: [req.query.event].flat() as string[],
2828
}
2929
}
3030

0 commit comments

Comments
 (0)