mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 18:13:29 +01:00
feat: Enforce limit of URLs for link buttons (#11011)
feat: enforce limit of URLs for link buttons
This commit is contained in:
@@ -32,7 +32,7 @@ const buttonDangerPredicate = buttonCustomIdPredicateBase.extend({ style: z.lite
|
||||
|
||||
const buttonLinkPredicate = buttonPredicateBase.extend({
|
||||
style: z.literal(ButtonStyle.Link),
|
||||
url: z.url({ protocol: /^(?:https?|discord)$/ }),
|
||||
url: z.url({ protocol: /^(?:https?|discord)$/ }).max(512),
|
||||
emoji: emojiPredicate.optional(),
|
||||
label: labelPredicate,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user