mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-07 20:54:28 +08:00
email.header: Make decode_header also accept str. (#333)
decode_header accepts a parameter of type str or Header, but the stub for decode_header types the parameter as Header. Change that to Union[Header, str].
This commit is contained in:
committed by
Guido van Rossum
parent
a424eeb1f8
commit
df1a655858
@@ -18,7 +18,7 @@ class Header:
|
||||
def __eq__(self, other: Any) -> bool: ...
|
||||
def __ne__(self, other: Any) -> bool: ...
|
||||
|
||||
def decode_header(header: Header) -> List[Tuple[bytes, Optional[str]]]: ...
|
||||
def decode_header(header: Union[Header, str]) -> List[Tuple[bytes, Optional[str]]]: ...
|
||||
def make_header(decoded_seq: List[Tuple[bytes, Optional[str]]],
|
||||
maxlinelen: Optional[int] =...,
|
||||
header_name: Optional[str] = ...,
|
||||
|
||||
Reference in New Issue
Block a user