mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Update Message.content_type property
This commit is contained in:
parent
17daa1e733
commit
ff28f19953
1 changed files with 6 additions and 0 deletions
|
|
@ -583,6 +583,8 @@ class Message(MaybeInaccessibleMessage):
|
|||
return ContentType.GIVEAWAY
|
||||
if self.giveaway_completed:
|
||||
return ContentType.GIVEAWAY_COMPLETED
|
||||
if self.giveaway_winners:
|
||||
return ContentType.GIVEAWAY_WINNERS
|
||||
if self.video_chat_scheduled:
|
||||
return ContentType.VIDEO_CHAT_SCHEDULED
|
||||
if self.video_chat_started:
|
||||
|
|
@ -599,6 +601,10 @@ class Message(MaybeInaccessibleMessage):
|
|||
return ContentType.CHAT_SHARED
|
||||
if self.story:
|
||||
return ContentType.STORY
|
||||
if self.has_media_spoiler:
|
||||
return ContentType.HAS_MEDIA_SPOILER
|
||||
if self.write_access_allowed:
|
||||
return ContentType.WRITE_ACCESS_ALLOWED
|
||||
|
||||
return ContentType.UNKNOWN
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue