discord title limit
This commit is contained in:
parent
df2b48f40e
commit
de84de78ae
1 changed files with 2 additions and 0 deletions
|
@ -224,6 +224,8 @@ def discord_send(channel, content, **args) -> bool:
|
||||||
dw = settings.DISCORD_WEBHOOKS.get(channel)
|
dw = settings.DISCORD_WEBHOOKS.get(channel)
|
||||||
if not dw:
|
if not dw:
|
||||||
return False
|
return False
|
||||||
|
if "thread_name" in args:
|
||||||
|
args["thread_name"] = args["thread_name"][:99]
|
||||||
webhook = SyncWebhook.from_url(dw)
|
webhook = SyncWebhook.from_url(dw)
|
||||||
webhook.send(content, **args)
|
webhook.send(content, **args)
|
||||||
return True
|
return True
|
||||||
|
|
Loading…
Add table
Reference in a new issue