Skip to content

Commit b1ef11e

Browse files
committed
Fix for machine errors
1 parent fc28c74 commit b1ef11e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

apps/webapp/app/presenters/v3/ApiRunListPresenter.server.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,12 @@ export const ApiRunListSearchParams = z.object({
126126
}
127127

128128
const parsedValues = values.map((v) => MachinePresetName.safeParse(v));
129-
const invalidValues = parsedValues.filter((result) => !result.success);
129+
const invalidValues: string[] = [];
130+
parsedValues.forEach((result, index) => {
131+
if (!result.success) {
132+
invalidValues.push(values[index]);
133+
}
134+
});
130135
if (invalidValues.length > 0) {
131136
ctx.addIssue({
132137
code: z.ZodIssueCode.custom,

0 commit comments

Comments
 (0)