Method: Discordrb::Channel#start_thread
- Defined in:
- lib/discordrb/data/channel.rb
#start_thread(name, auto_archive_duration, message: nil, type: 11) ⇒ Channel
Start a thread.
986 987 988 989 990 991 992 993 994 995 996 997 |
# File 'lib/discordrb/data/channel.rb', line 986 def start_thread(name, auto_archive_duration, message: nil, type: 11) = &.id || type = TYPES[type] || type data = if API::Channel.(@bot.token, @id, , name, auto_archive_duration) else API::Channel.(@bot.token, @id, name, auto_archive_duration, type) end Channel.new(JSON.parse(data), @bot, @server) end |