mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-04-22 08:44:10 +00:00
Allow empty strings to be in Embed.to_dict
This commit is contained in:
parent
4adfde1a7b
commit
a72fc7416c
@ -742,16 +742,16 @@ class Embed:
|
||||
result['timestamp'] = timestamp.replace(tzinfo=datetime.timezone.utc).isoformat()
|
||||
|
||||
# add in the non raw attribute ones
|
||||
if self.type:
|
||||
if self.type is not None:
|
||||
result['type'] = self.type
|
||||
|
||||
if self.description:
|
||||
if self.description is not None:
|
||||
result['description'] = self.description
|
||||
|
||||
if self.url:
|
||||
if self.url is not None:
|
||||
result['url'] = self.url
|
||||
|
||||
if self.title:
|
||||
if self.title is not None:
|
||||
result['title'] = self.title
|
||||
|
||||
return result # type: ignore # This payload is equivalent to the EmbedData type
|
||||
|
Loading…
x
Reference in New Issue
Block a user