i have this code that would change an embed’s footer and resend it to the log channel, but now it doesn’t work anymore for somereason
this is the code:
if message.channel == bot_commands_channel: for em in message.embeds: em.set_footer('''new footer''') await log_channel.send(embed=em) return
and this is the error i get:
File "main.py", line 297, in on_message em.set_footer('''new footer''') TypeError: set_footer() takes 1 positional argument but 2 were given
Advertisement
Answer
The argument for set_footer
is keyword-only:
embed.set_footer(text='''new footer''') # note the `text=...`