From cb28e470c2fdc26882151934be66bbff96350055 Mon Sep 17 00:00:00 2001 From: Barani Kumar S Date: Sat, 26 Oct 2024 00:38:54 +0530 Subject: [PATCH] discord: Minor wordings and comment fix --- discord/component.go | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/discord/component.go b/discord/component.go index 9e88257..954a951 100644 --- a/discord/component.go +++ b/discord/component.go @@ -853,13 +853,13 @@ type DefaultMention struct { roleId RoleID `json:"-"` } -// Creates new DefaultMention type with only UserID -func UserMention (userId UserID) DefaultMention { +// Creates new DefaultUserMention type with only UserID +func DefaultUserMention (userId UserID) DefaultMention { return DefaultMention{userId: userId} } -// Creates new DefaultMention type with only RoleID -func RoleMention(roleId RoleID) DefaultMention { +// Creates new DefaultRoleMention type with only RoleID +func DefaultRoleMention(roleId RoleID) DefaultMention { return DefaultMention{roleId: roleId} } @@ -876,7 +876,11 @@ type MentionableSelectComponent struct { Disabled bool `json:"disabled,omitempty"` // DefaultMentions is the slice of User / Role Mentions that are selected by default // Example: - // DefaultMentions: []DefaultMention{ discord.UserMention(0382080830233), discord.RoleMention(4820380382080) } + // DefaultMentions: []DefaultMention{ + // discord.DefaultUserMention(0382080830233), + // discord.DefaultRoleMention(4820380382080), + // ... + // } DefaultMentions []DefaultMention `json:"-"` }