Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ChannelMessageSendComplex #349

Merged
merged 5 commits into from
Apr 8, 2017
Merged

ChannelMessageSendComplex #349

merged 5 commits into from
Apr 8, 2017

Conversation

jD91mZM2
Copy link
Contributor

@jD91mZM2 jD91mZM2 commented Apr 5, 2017

I was getting tired of all the ChannelMessageSendThisWithThisAndThisAndThis.
So, well, this is my solution.

I kept the others for compatibility. And ChannelMessageSend should always be kept for ease of use.

Anyways, I'm unsure whether I should also include ChannelFileSend in this as well. It'd certainly be useful (sending embeds and files together, maybe).
But that's for later.

restapi.go Outdated
@@ -1332,23 +1324,7 @@ func (s *Session) ChannelMessageSendEmbed(channelID string, embed *MessageEmbed)
// content : The message to send.
// embed : The embed data to send.
func (s *Session) ChannelMessageSendEmbedWithMessage(channelID string, content string, embed *MessageEmbed) (st *Message, err error) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call, let's kill this method, it was added in develop, I don't care too much to keep it around.

@iopred
Copy link
Collaborator

iopred commented Apr 5, 2017

We should probably add EditComplex also.

@jD91mZM2
Copy link
Contributor Author

jD91mZM2 commented Apr 5, 2017

I was going to do that, but Edit doesn't have as many functions and combinations. At all.

EDIT: Whatever, it still allows you to combine them.

restapi.go Outdated

err = unmarshal(response, &st)
return
func (s *Session) ChannelMessageSendEmbedWithMessage(channelID string, content string, embed *MessageEmbed) (*Message, error) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's just kill this guy, WDYT?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Personally, yes. But it deserves mercy, too. And because I'm the kind of person that likes compatibility.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love me some compatibility, but this method never made it to master.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok you're right. I will remove them

message.go Outdated
Content string `json:"content"`
Tts bool `json:"tts"`
Embed *MessageEmbed `json:"embed"`
Nounce string `json:"nounce"`
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is nonce

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oohh, right. Thanks. Will fix!

@iopred iopred merged commit fea42d9 into bwmarrin:develop Apr 8, 2017
@jD91mZM2 jD91mZM2 deleted the 1 branch April 8, 2017 06:31
@bwmarrin bwmarrin added this to the v0.16.0 milestone Apr 18, 2017
ErikMcClure pushed a commit to ErikMcClure/discordgo that referenced this pull request Aug 4, 2020
* ChannelMessageSendComplex

* ChannelMessageEditComplex

* I am a murderer.

* Travis didn't like that.

* I can't spell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants