diff --git a/types/hapi/index.d.ts b/types/hapi/index.d.ts index 10741806c3..dec96e0c6c 100644 --- a/types/hapi/index.d.ts +++ b/types/hapi/index.d.ts @@ -1436,13 +1436,11 @@ export interface RouteOptionsPreObject { failAction?: Lifecycle.FailAction; } -export interface ValidationObject { - [key: string]: AnySchema; -} +export type ValidationObject = SchemaMap; export type RouteOptionsResponseSchema = boolean - | SchemaMap + | ValidationObject | Schema | ((value: object | Buffer | string, options: ValidationOptions) => Promise);