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

News channel message publish #1530

Merged
merged 5 commits into from
May 20, 2020
Merged

News channel message publish #1530

merged 5 commits into from
May 20, 2020

Conversation

MattTheDev
Copy link
Contributor

@MattTheDev MattTheDev commented May 13, 2020

Summary

This PR adds in the ability to Publish a new message within a news chnanel. If the channel type is not a news channel, it'll ignore the request to publish. I thought about returning an error here, and this could easily be added.

Resolves #1528

Changes

Addition of the API handler for /crosspost endpoint.
Addition of PublishAsync to the Socket and Rest Messages.
Only executes if the channels are news channel types.

@MattTheDev
Copy link
Contributor Author

Great feedback, @SubZero0. Working on resolving them now.

2. Clarified xml docs
3. Properly threw exceptions instead of failing silently.
Copy link
Member

@Still34 Still34 left a comment

Choose a reason for hiding this comment

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

Docs strings need to be tidied up before merge.

Copy link
Contributor Author

@MattTheDev MattTheDev left a comment

Choose a reason for hiding this comment

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

Modified per your request.

@MattTheDev MattTheDev requested a review from Still34 May 18, 2020 06:42
@foxbot foxbot merged commit a6c1e4c into discord-net:dev May 20, 2020
anonymousheadless pushed a commit to anonymousheadless/Discord.Net that referenced this pull request Mar 29, 2021
* Added PublishAsync to Messages.

* Added missing implementation.

* 1. Aligned with naming standards
2. Clarified xml docs
3. Properly threw exceptions instead of failing silently.

* Additional documentation included.

* Removed un-needed comments.

Co-authored-by: Matt Smith <v-matsm@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Addition of crosspost endpoint support for news channels
4 participants