Skip to content
This repository was archived by the owner on Mar 8, 2022. It is now read-only.

Commit adf10c4

Browse files
author
kuso-senpai
committed
removed print statements
2 parents c7748f8 + c8ab4d5 commit adf10c4

File tree

5 files changed

+6
-9
lines changed

5 files changed

+6
-9
lines changed

discord_ui/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,4 +43,4 @@
4343

4444

4545
__title__ = "discord-ui"
46-
__version__ = "3.3.3"
46+
__version__ = "3.3.3"

discord_ui/override.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ async def send(self: discord.TextChannel, content=None, **kwargs) -> Message:
6363
return msg
6464
def message_override(cls, *args, **kwargs):
6565
if cls is discord.message.Message:
66-
print("override message")
6766
return object.__new__(Message)
6867
else:
6968
return object.__new__(cls)

discord_ui/receive.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -430,9 +430,8 @@ def _update_components(self, data):
430430
def _update(self, data):
431431
super()._update(data)
432432
self._update_components(data)
433-
print("updated components", [type(x) for x in self.components])
434433

435-
async def edit(self, *, content=MISSING, embeds=MISSING, attachments=MISSING, suppress=MISSING,
434+
async def edit(self, *, content=MISSING, embed=MISSING, embeds=MISSING, attachments=MISSING, suppress=MISSING,
436435
delete_after=MISSING, allowed_mentions=MISSING, components=MISSING):
437436
"""Edits the message and updates its properties
438437
@@ -444,6 +443,8 @@ async def edit(self, *, content=MISSING, embeds=MISSING, attachments=MISSING, su
444443
----------------
445444
content: :class:`str`
446445
The new message content
446+
embed: :class:`discord.Embed`
447+
The new embed of the message
447448
embeds: List[:class:`discord.Embed`]
448449
The new list of discord embeds
449450
attachments: List[:class:`discord.Attachment`]
@@ -457,9 +458,7 @@ async def edit(self, *, content=MISSING, embeds=MISSING, attachments=MISSING, su
457458
components: List[:class:`~Button` | :class:`~LinkButton` | :class:`~SelectMenu`]
458459
A list of components to be included the message
459460
"""
460-
payload = jsonifyMessage(content, embeds=embeds, allowed_mentions=allowed_mentions, attachments=attachments, suppress=suppress, flags=self.flags.value, components=components)
461-
if suppress:
462-
self.suppressed = suppress
461+
payload = jsonifyMessage(content, embed=embed, embeds=embeds, allowed_mentions=allowed_mentions, attachments=attachments, suppress=suppress, flags=self.flags.value, components=components)
463462
data = await self._state.http.edit_message(self.channel.id, self.id, **payload)
464463
self._update(data)
465464

discord_ui/slash/http.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ async def delete_guild_command(client: com.Bot, command_id, guild_id):
4949
else:
5050
raise ex
5151
except Exception as ex:
52-
print("caught exception", ex)
52+
raise ex
5353

5454
async def get_command_permissions(client: com.Bot, command_id, guild_id):
5555
try:

discord_ui/slash/types.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ def __init__(self, argument_type, name, description=MISSING, required=False, cho
5757
def __repr__(self) -> str:
5858
return f"<discord_ui.SlashOption({str(self.to_dict())})>"
5959
def __eq__(self, o: object) -> bool:
60-
print("check", o)
6160
if isinstance(o, SlashOption):
6261
return (self.argument_type == o.argument_type and self.name == o.name and self.description == o.description and self.required == o.required and self.choices == o.choices and self.options == o.options)
6362
elif isinstance(o, dict):

0 commit comments

Comments
 (0)