We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0a11352 commit 5b07682Copy full SHA for 5b07682
1 file changed
transfunctions/transformer.py
@@ -83,7 +83,7 @@ def get_async_function(self) -> Callable[FunctionParams, Coroutine[Any, Any, Ret
83
original_function = self.function
84
85
class ConvertSyncFunctionToAsync(NodeTransformer):
86
- def visit_FunctionDef(self, node: FunctionDef) -> Optional[Union[AST, List[AST]]]:
+ def visit_FunctionDef(self, node: FunctionDef) -> Union[FunctionDef, AsyncFunctionDef]:
87
if node.name == original_function.__name__:
88
return AsyncFunctionDef(
89
name=original_function.__name__,
0 commit comments