Skip to content

Commit

Permalink
fix: properly type predicate error parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
Planeshifter committed Feb 24, 2024
1 parent 174544f commit 952ea72
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ type PredicateUnary = ( error: Error ) => void;
* @param error - error object
* @param bool - condition used to determine whether to invoke callback with `x` or `y`
*/
type PredicateBinary = ( error: Error, bool: boolean ) => void;
type PredicateBinary = ( error: Error | null, bool: boolean ) => void;

/**
* Predicate callback function.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ type PredicateUnary = ( error: Error ) => void;
* @param error - error object
* @param bool - condition used to determine whether to invoke `x` or `y`
*/
type PredicateBinary = ( error: Error, bool: boolean ) => void;
type PredicateBinary = ( error: Error | null, bool: boolean ) => void;

/**
* Predicate callback function.
Expand Down

0 comments on commit 952ea72

Please sign in to comment.