mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-29 12:53:44 +03:00
TLObject.stringify() was showing bytes as lists
This commit is contained in:
parent
2e55998d7f
commit
2517b9787d
|
@ -47,8 +47,8 @@ class TLObject:
|
||||||
k, TLObject.pretty_format(v)
|
k, TLObject.pretty_format(v)
|
||||||
) for k, v in obj.items()
|
) for k, v in obj.items()
|
||||||
))
|
))
|
||||||
elif isinstance(obj, str):
|
elif isinstance(obj, str) or isinstance(obj, bytes):
|
||||||
return '"{}"'.format(obj)
|
return repr(obj)
|
||||||
elif hasattr(obj, '__iter__'):
|
elif hasattr(obj, '__iter__'):
|
||||||
return '[{}]'.format(
|
return '[{}]'.format(
|
||||||
', '.join(TLObject.pretty_format(x) for x in obj)
|
', '.join(TLObject.pretty_format(x) for x in obj)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user