does someone know how to publish a message by a user? I have already tried a bit and asked on a discord coding server, but I didn't got a good answer.
I tried something like this:
@client.event
async def on_message(message):
if message.channel.type == discord.ChannelType.news:
await message.publish
return
Today I had the same problem and I fixed it with:
@client.command()
async def sendMessage(ctx, message):
msg = await ctx.send("Published message: " + message)
await msg.publish()
So I think you forgot the brackets. So this code would work:
@client.event
async def on_message(message):
if message.channel.type == discord.ChannelType.news:
await message.publish()
return
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With