Telethon/telethon_generator
Lonami Exo fa736f81af Handle all entity types on isinstance checks
Only the uses of `isinstance` against `InputPeer*` types were
reviewed. Notably, `utils` is exempt on this because it needs
to deal with everything on a case-by-case basis.

Since the addition of `*FromMessage` peers, any manual `isinstance`
checks to determine the type were prone to breaking or being
forgotten to be updated, so a common `helpers._entity_type()`
method was made to share this logic.

Since the conversion to `Peer` would be too expensive, a simpler
check against the name is made, which should be fast and cheap.
2019-12-23 13:52:07 +01:00
..
data Handle all entity types on isinstance checks 2019-12-23 13:52:07 +01:00
generators Clean-up usage of root directory in docs generation 2019-07-17 10:11:52 +02:00
parsers Sleep automatically on slow mode error too (#1279) 2019-09-24 11:37:41 +02:00
__init__.py Add missing __init__.py to telethon_generator package (#382) 2017-10-25 19:48:46 +02:00
docswriter.py Clean-up usage of root directory in docs generation 2019-07-17 10:11:52 +02:00
sourcebuilder.py Remove underscore from module names 2018-06-18 21:02:42 +02:00
utils.py Fix wrong camel case for all names 2018-04-14 19:04:07 +02:00