Remove omitempty
for Embeds
(#1106)
* do not omit empty .Embeds so we can clear embeds when editing. * also do not omitempty for required: false in text inputs.
This commit is contained in:
parent
ee34db7ade
commit
9586f7fb38
3 changed files with 4 additions and 4 deletions
|
@ -208,7 +208,7 @@ type TextInput struct {
|
|||
Style TextInputStyle `json:"style"`
|
||||
Placeholder string `json:"placeholder,omitempty"`
|
||||
Value string `json:"value,omitempty"`
|
||||
Required bool `json:"required,omitempty"`
|
||||
Required bool `json:"required"`
|
||||
MinLength int `json:"min_length,omitempty"`
|
||||
MaxLength int `json:"max_length,omitempty"`
|
||||
}
|
||||
|
|
|
@ -509,7 +509,7 @@ type InteractionResponseData struct {
|
|||
TTS bool `json:"tts"`
|
||||
Content string `json:"content"`
|
||||
Components []MessageComponent `json:"components"`
|
||||
Embeds []*MessageEmbed `json:"embeds,omitempty"`
|
||||
Embeds []*MessageEmbed `json:"embeds"`
|
||||
AllowedMentions *MessageAllowedMentions `json:"allowed_mentions,omitempty"`
|
||||
Flags uint64 `json:"flags,omitempty"`
|
||||
Files []*File `json:"-"`
|
||||
|
|
|
@ -225,7 +225,7 @@ type File struct {
|
|||
// MessageSend stores all parameters you can send with ChannelMessageSendComplex.
|
||||
type MessageSend struct {
|
||||
Content string `json:"content,omitempty"`
|
||||
Embeds []*MessageEmbed `json:"embeds,omitempty"`
|
||||
Embeds []*MessageEmbed `json:"embeds"`
|
||||
TTS bool `json:"tts"`
|
||||
Components []MessageComponent `json:"components"`
|
||||
Files []*File `json:"-"`
|
||||
|
@ -244,7 +244,7 @@ type MessageSend struct {
|
|||
type MessageEdit struct {
|
||||
Content *string `json:"content,omitempty"`
|
||||
Components []MessageComponent `json:"components"`
|
||||
Embeds []*MessageEmbed `json:"embeds,omitempty"`
|
||||
Embeds []*MessageEmbed `json:"embeds"`
|
||||
AllowedMentions *MessageAllowedMentions `json:"allowed_mentions,omitempty"`
|
||||
|
||||
ID string
|
||||
|
|
Loading…
Reference in a new issue