Skip to content

Commit ddef6cb

Browse files
committed
Added AllowedMentions support
1 parent 25cb969 commit ddef6cb

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

discord_slash/model.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ async def send(self,
3939
send_type: int = 4,
4040
text: str = "",
4141
embeds: typing.List[discord.Embed] = None,
42-
tts: bool = False):
42+
tts: bool = False,
43+
allowed_mentions: typing.List[discord.AllowedMentions] = None):
4344
"""
4445
Sends response of the slash command.
4546
@@ -61,7 +62,7 @@ async def send(self,
6162
"tts": tts,
6263
"content": text,
6364
"embeds": [x.to_dict() for x in embeds] if embeds else [],
64-
"allowed_mentions": []
65+
"allowed_mentions": [x.to_dict() for x in allowed_mentions] if allowed_mentions else self._discord.allowed_mentions.to_dict()
6566
}
6667
}
6768
initial = True if not self.sent else False

0 commit comments

Comments
 (0)