Skip to content

Commit bd734b5

Browse files
committed
fix: update build function type hint to use value_type for improved type safety
1 parent 895aa0e commit bd734b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fastapi_mason/lookups.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def build(cls, item_id: T = Path(..., alias=lookup_url_kwarg)) -> 'BaseLookup[T]
2828

2929

3030
def build_lookup_class(class_name: str, lookup_url_kwarg: str, value_type: Type[T]) -> Type[BaseLookup[T]]:
31-
def build(cls, value: T = Path(alias=lookup_url_kwarg)) -> BaseLookup[T]:
31+
def build(cls, value: value_type = Path(alias=lookup_url_kwarg)) -> BaseLookup[T]: # type: ignore
3232
return cls(**{'value': value})
3333

3434
class_dict = {

0 commit comments

Comments
 (0)