mirror of
https://github.com/Rapptz/discord.py.git
synced 2026-11-20 13:29:03 +00:00
Allow creating a public thread without a starter message
This commit is contained in:
1 parent
13251da8ce
commit
dac0267e28
3 files changed
+17
-11
No files matched your search
+1
-2
@@ -1511,12 +1511,11 @@ class Message(Hashable):
|
||||
if self.guild is None:
|
||||
raise InvalidArgument('This message does not have guild info attached.')
|
||||
|
||||
data = await self._state.http.start_public_thread(
|
||||
data = await self._state.http.start_thread_with_message(
|
||||
self.channel.id,
|
||||
self.id,
|
||||
name=name,
|
||||
auto_archive_duration=auto_archive_duration,
|
||||
type=ChannelType.public_thread.value,
|
||||
)
|
||||
return Thread(guild=self.guild, state=self._state, data=data) # type: ignore
|
||||
|
||||
|
||||
Reference in new issue
Block a user