chore: replace oxlint with biome for linting
This commit is contained in:
@@ -14,7 +14,10 @@ const onInvalid: Hook<unknown, Env, string> = (result, c: Context) => {
|
||||
|
||||
for (const issue of (result.error as ZodError).issues) {
|
||||
const path = issue.path.length > 0 ? issue.path.map(String).join('.') : '_root'
|
||||
;(fieldErrors[path] ??= []).push(issue.message)
|
||||
const messages = fieldErrors[path] ?? []
|
||||
|
||||
messages.push(issue.message)
|
||||
fieldErrors[path] = messages
|
||||
}
|
||||
|
||||
return c.body(JSON.stringify(problems.validation(fieldErrors)), 422, {
|
||||
|
||||
Reference in New Issue
Block a user