This commit is contained in:
Kadir Can Ozden 2026-02-24 07:02:20 +03:00 committed by GitHub
commit e22bb0f1a8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -89,7 +89,9 @@ def to_bytes_or_str(value: str, match_type_of: typing.AnyStr) -> typing.AnyStr:
def unquote(value: str) -> str:
return value[1:-1] if value[0] == value[-1] == '"' else value
if len(value) >= 2 and value[0] == value[-1] == '"':
return value[1:-1]
return value
def peek_filelike_length(stream: typing.Any) -> int | None: