mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Add __str__ formatting to the TelegramObject
This commit is contained in:
parent
5b20f81654
commit
e9a7714c5a
1 changed files with 3 additions and 0 deletions
|
|
@ -17,6 +17,9 @@ class TelegramObject(ContextInstanceMixin["TelegramObject"], BaseModel):
|
|||
allow_population_by_field_name = True
|
||||
json_encoders = {datetime.datetime: lambda dt: int(dt.timestamp())}
|
||||
|
||||
def __str__(self) -> str:
|
||||
return self.__repr__()
|
||||
|
||||
|
||||
class MutableTelegramObject(TelegramObject):
|
||||
class Config:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue