diff --git a/src/plugins/WebhookManager/index.tsx b/src/plugins/WebhookManager/index.tsx index 588139807..341eeddc5 100644 --- a/src/plugins/WebhookManager/index.tsx +++ b/src/plugins/WebhookManager/index.tsx @@ -126,8 +126,8 @@ export default definePlugin({ }, { name: "pfp", - description: "Send with a custom profile picture.", - type: ApplicationCommandOptionType.ATTACHMENT, + description: "Send with a custom profile picture. You must input a valid image URL.", + type: ApplicationCommandOptionType.STRING, required: false }, { @@ -141,7 +141,7 @@ export default definePlugin({ const webhookUrl = findOption(option, "url"); const webhookMessage = findOption(option, "message"); - const webhookProfilePic = findOption(option, "pfp"); + let webhookProfilePic = findOption(option, "pfp"); let webhookUsername = findOption(option, "username"); if (findOption(option, "raw")) { Native.executeWebhook("" + webhookUrl, { @@ -153,6 +153,10 @@ export default definePlugin({ webhookUsername = undefined; } + if (webhookProfilePic === "") { + webhookProfilePic = undefined; + } + Native.executeWebhook("" + webhookUrl, { content: webhookMessage, username: webhookUsername,