Skip to content

Commit 9f6caa3

Browse files
committed
fixed mypy lint error
1 parent 31e168c commit 9f6caa3

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

ninja_extra/controllers/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ def __call__(self, cls: ControllerClassType) -> ControllerClassType:
458458
fail_silently(inject, constructor_or_class=cls)
459459

460460
ControllerRegistry().add_controller(cls)
461-
return cls # type: ignore[return-value]
461+
return cls
462462

463463
@property
464464
def path_operations(self) -> Dict[str, PathView]:

ninja_extra/controllers/model/path_resolver.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def __init__(self, path: str, func: t.Callable) -> None:
111111
)
112112
self.as_view = functools.wraps(func)(self.get_view_function())
113113
else:
114-
self.as_view = func
114+
self.as_view = func # type:ignore[assignment]
115115

116116
def get_path_fields(self) -> t.Generator:
117117
for path_name, path_type in self.compiled_path.param_convertors.items():

ninja_extra/controllers/route/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ def _create_route_function(
150150
if not isinstance(type_hint, t._SpecialForm):
151151
response = type_hint
152152
route_obj = cls(
153-
view_func,
153+
view_func, # type:ignore[arg-type]
154154
path=path,
155155
methods=methods,
156156
auth=auth,

0 commit comments

Comments
 (0)