Skip to content

Commit ae05877

Browse files
committed
Add return type annotation to method_call function
- Add explicit return type annotation (-> Any) to method_call function - Add explicit return None at end of function for clarity
1 parent 486eee9 commit ae05877

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/pynecore/core/pine_method.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def method(func: Callable) -> Callable:
1818

1919

2020
# noinspection PyShadowingNames
21-
def method_call(method: str | Callable, var: Any, *args, **kwargs):
21+
def method_call(method: str | Callable, var: Any, *args, **kwargs) -> Any:
2222
global __scope_id__
2323

2424
# If method is a string
@@ -38,3 +38,5 @@ def method_call(method: str | Callable, var: Any, *args, **kwargs):
3838
# It is a local method, it should be a local function
3939
elif callable(method):
4040
return isolate_function(method, '__method_call__', __scope_id__)(var, *args, **kwargs)
41+
42+
return None

0 commit comments

Comments
 (0)