Closed houxul closed 9 months ago
msgEdit := &discordgo.MessageEdit{ Channel: message.ChannelId, ID: message.MessageId, Content: &content, Flags: discordgo.MessageFlagsEphemeral, } _, err := s.sess.ChannelMessageEditComplex(msgEdit)
Call the above code and set Flags to discordgo.MessageFlagsEphemeral, when the message has not changed to be visible only to the current user. The following is the definition of MessageFlagsEphemeral. https://github.com/bwmarrin/discordgo/blob/master/message.go#L212-L213
MessageFlagsEphemeral cannot be set when editing a message. In addition to that, it is only available when responding to an interaction.
MessageFlagsEphemeral
Call the above code and set Flags to discordgo.MessageFlagsEphemeral, when the message has not changed to be visible only to the current user. The following is the definition of MessageFlagsEphemeral. https://github.com/bwmarrin/discordgo/blob/master/message.go#L212-L213