Skip to content

Conversation

Donbur4156
Copy link
Contributor

@Donbur4156 Donbur4156 commented May 28, 2023

Pull Request Type

  • Feature addition
  • Bugfix
  • Documentation update
  • Code refactor
  • Tests improvement
  • CI/CD pipeline enhancement
  • Other: [Replace with a description]

Description

Allowing list of Roles in CustomEmoji.edit() by converting it to snowflake_list.

Changes

add to_snowflake_list() to convert list of Roles into list of snowflakes, according the roles argument definition.

Related Issues

#1426

Test Scenarios

role1, role2 = interactions.Role(...)
emoji = await guild.fetch_custom_emoji(emoji_id=emoji_id)
await emoji.edit(roles=[role1, role2])

Python Compatibility

  • I've ensured my code works on Python 3.10.x
  • I've ensured my code works on Python 3.11.x

Checklist

  • I've run the pre-commit code linter over all edited files
  • I've tested my changes on supported Python versions
  • I've added tests for my code, if applicable
  • I've updated / added documentation, where applicable

add to_snowflake_list() to convert list of Roles into list of snowflakes, according the roles argument definition.
@Donbur4156 Donbur4156 changed the base branch from stable to unstable May 30, 2023 11:54
@LordOfPolls LordOfPolls merged commit 996e43e into interactions-py:unstable May 31, 2023
@Donbur4156 Donbur4156 deleted the fix_roleslist_in_emoji_edit branch July 28, 2023 14:10
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.

3 participants