mirror of https://github.com/celery/kombu.git
Add spacing between `@overload`'ed functions to fix E302 errors
This commit is contained in:
parent
a7ee273569
commit
4f51694275
|
@ -45,8 +45,12 @@ else:
|
|||
|
||||
@overload
|
||||
def str_to_bytes(s: str) -> bytes: ...
|
||||
|
||||
|
||||
@overload
|
||||
def str_to_bytes(s: T) -> T: ...
|
||||
|
||||
|
||||
def str_to_bytes(s: Any) -> Any:
|
||||
"""Convert str to bytes."""
|
||||
if isinstance(s, str):
|
||||
|
@ -56,8 +60,12 @@ def str_to_bytes(s: Any) -> Any:
|
|||
|
||||
@overload
|
||||
def bytes_to_str(s: bytes) -> str: ...
|
||||
|
||||
|
||||
@overload
|
||||
def bytes_to_str(s: T) -> T: ...
|
||||
|
||||
|
||||
def bytes_to_str(s: Any) -> Any:
|
||||
"""Convert bytes to str."""
|
||||
if isinstance(s, bytes):
|
||||
|
|
Loading…
Reference in New Issue