mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-06-07 12:18:59 +00:00
Fix bug in Embed.__len__ caused by footer without text
This commit is contained in:
parent
f56543df15
commit
f42e922696
@ -273,11 +273,11 @@ class Embed:
|
|||||||
total += len(field['name']) + len(field['value'])
|
total += len(field['name']) + len(field['value'])
|
||||||
|
|
||||||
try:
|
try:
|
||||||
footer = self._footer
|
footer_text = self._footer['text']
|
||||||
except AttributeError:
|
except (AttributeError, KeyError):
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
total += len(footer['text'])
|
total += len(footer_text)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
author = self._author
|
author = self._author
|
||||||
|
Loading…
x
Reference in New Issue
Block a user