Skip to content

Commit

Permalink
core: Avoid using Python's union syntax
Browse files Browse the repository at this point in the history
So we don't depend on Python >= 3.10.
  • Loading branch information
oleavr committed Oct 6, 2022
1 parent acafa09 commit 6470583
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frida/core.py
Expand Up @@ -330,7 +330,7 @@ def list_exports(self) -> List[str]:
def _rpc_request(self, *args: Any) -> Any:
result = RPCResult()

def on_complete(value: Any, error: Union[None, RPCException | _frida.InvalidOperationError]) -> None:
def on_complete(value: Any, error: Union[None, Union[RPCException, _frida.InvalidOperationError]]) -> None:
with self._cond:
result.finished = True
result.value = value
Expand Down

0 comments on commit 6470583

Please sign in to comment.