Skip to content

Commit 706d4de

Browse files
committed
added missing imports
1 parent 977e44f commit 706d4de

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/runtime/server/utils/definePrecognitionEventHandler.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { type EventHandler, type EventHandlerRequest, type H3Event, setResponseHeader } from 'h3'
22
import type { ZodSchema, ZodObject } from 'zod'
33
import { z } from 'zod'
4-
import { defineEventHandler } from 'h3'
4+
import { defineEventHandler, getHeaders } from 'h3'
55
import getValidatedInput from './getValidatedInput'
66

77
const precognitionEventHandler = <T extends EventHandlerRequest, D> (

src/runtime/server/utils/getValidatedInput.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { type H3Event } from 'h3'
22
import type { ZodObject } from 'zod'
3-
import { readValidatedBody } from 'h3'
3+
import { readValidatedBody, createError } from 'h3'
44

55
export default async function<T>(event: H3Event, validationSchema: ZodObject<unknown>) {
66
const body = await readValidatedBody<T>(event, body => validationSchema.safeParse(body))

0 commit comments

Comments
 (0)