Skip to content
This repository has been archived by the owner on Dec 12, 2020. It is now read-only.

Commit

Permalink
fix: Fix partial decorator to match tinspector type (#59)
Browse files Browse the repository at this point in the history
  • Loading branch information
ktutnik committed Jun 4, 2020
1 parent f2ec462 commit 6f5528e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/decorators.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { TypeOverride } from "tinspector"
import validatorJs from "validator"
import * as v from './validation';
import { Class } from './types';

import * as v from "./validation"

interface Opt { message?: string }

Expand Down Expand Up @@ -209,7 +210,7 @@ namespace val {
return v.required()
}

export function partial(typ: Class) {
export function partial(typ: TypeOverride | ((x: any) => TypeOverride)) {
return v.partial(typ)
}
}
Expand Down

0 comments on commit 6f5528e

Please sign in to comment.