discordgo icon indicating copy to clipboard operation
discordgo copied to clipboard

omitempty on complex edits don't work properly

Open cryptiklemur opened this issue 4 years ago • 1 comments

Setting any scalar field to their "empty" value doesnt work. Examples:

  • Channels
    • remove NSFW on a channel
    • remove a topic
    • remove a user limit on VCs
    • change the position to 0
    • remove a channel from a category
  • Server
    • turn off the default message notifications
    • remove a verification level
    • remove an afk timeout
    • remove an afk channel id
    • remove an icon

I'm sure theres more

cryptiklemur avatar Aug 17 '20 23:08 cryptiklemur

Time for an abstraction!

On Mon, Aug 17, 2020 at 4:15 PM Aaron Scherer [email protected] wrote:

Setting any scalar field to their "empty" value doesnt work. Examples:

  • Channels
    • remove NSFW on a channel
    • remove a topic
    • remove a user limit on VCs
    • change the position to 0
    • remove a channel from a category
  • Server
    • turn off the default message notifications
    • remove a verification level
    • remove an afk timeout
    • remove an afk channel id
    • remove an icon

I'm sure theres more

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/bwmarrin/discordgo/issues/808, or unsubscribe https://github.com/notifications/unsubscribe-auth/AALVLAS6RBA5YBPUEZTW74LSBG227ANCNFSM4QCL7IHA .

iopred avatar Aug 18 '20 00:08 iopred