Skip to content

Commit

Permalink
better types
Browse files Browse the repository at this point in the history
  • Loading branch information
willemgovaerts committed Jan 5, 2023
1 parent b641e58 commit 454f915
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
// tslint:disable:no-submodule-imports ban-types
import * as cv from 'class-validator'
import { ConstraintMetadata } from 'class-validator/types/metadata/ConstraintMetadata'
import { ValidationMetadata } from 'class-validator/types/metadata/ValidationMetadata'
import _groupBy from 'lodash.groupby'
import _merge from 'lodash.merge'
Expand All @@ -13,9 +12,8 @@ import { defaultOptions, IOptions } from './options'
export { JSONSchema } from './decorators'

type IStorage = {
validationMetadatas: Map<any, ValidationMetadata[]>
constraintMetadatas: Map<any, ConstraintMetadata[]>
} & Omit<cv.MetadataStorage, 'validationMetadatas' | 'constraintMetadatas'>
validationMetadatas: Map<Function | string, ValidationMetadata[]>
} & Omit<cv.MetadataStorage, 'validationMetadatas'>

/**
* Convert class-validator metadata into JSON Schema definitions.
Expand Down

0 comments on commit 454f915

Please sign in to comment.