Skip to content

Commit

Permalink
Merge pull request #2290 from Badiboy/master
Browse files Browse the repository at this point in the history
Fix MessageEntity.user if None
  • Loading branch information
Badiboy authored Jun 2, 2024
2 parents 139d35f + 67230b8 commit 0927d2d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion telebot/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -1665,7 +1665,7 @@ def to_dict(self):
"offset": self.offset,
"length": self.length,
"url": self.url,
"user": self.user.to_dict(),
"user": self.user.to_dict() if self.user else None,
"language": self.language,
"custom_emoji_id": self.custom_emoji_id}

Expand Down

0 comments on commit 0927d2d

Please sign in to comment.