Skip to content

Commit

Permalink
remove redundant cast
Browse files Browse the repository at this point in the history
  • Loading branch information
tlambert03 committed Dec 16, 2023
1 parent 0111d33 commit a54f27d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/in_n_out/_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -1146,7 +1146,7 @@ def _validate_provider(obj: T | Callable[[], T]) -> Callable[[], T]:
Can either be a function or an object. If a non-callable is passed, a function
that returns it is created.
"""
return obj if callable(obj) else (lambda: cast(T, obj))
return obj if callable(obj) else (lambda: obj)


def _validate_processor(obj: Callable[[T], Any]) -> Callable[[T], Any]:
Expand Down

0 comments on commit a54f27d

Please sign in to comment.