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

feat(MessageEmbed): add setFields method #6186

Merged
merged 3 commits into from
Jul 31, 2021

Conversation

ImRodry
Copy link
Contributor

@ImRodry ImRodry commented Jul 26, 2021

Please describe the changes this PR makes and why it should be merged:
This PR adds a setFields method to MessageEmbed that overwrites the current fields in the MessageEmbed with the provided ones.

Status and versioning classification:

  • Code changes have been tested against the Discord API, or there are no code changes
  • I know how to update typings and have done so, or typings don't need updating
  • This PR changes the library's interface (methods or parameters added)

@iCrawl iCrawl added this to the Version 13 milestone Jul 27, 2021
@ImRodry
Copy link
Contributor Author

ImRodry commented Jul 29, 2021

Changed it to use spliceFields internally so that the object isn't reassigned.

src/structures/MessageEmbed.js Outdated Show resolved Hide resolved
@iCrawl iCrawl merged commit a25e165 into discordjs:master Jul 31, 2021
@ImRodry ImRodry deleted the messageembed-setfields branch July 31, 2021 12:19
IRONM00N pushed a commit to TanzaniteBot/discord.js that referenced this pull request Aug 1, 2021
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.

5 participants