WIP: feature: threads'n'forums #74

Draft
Guzio wants to merge 109 commits from Guzio/out-of-your-element:mergable-fr-fr into main
Showing only changes of commit 81758529ba - Show all commits

View file

@ -91,6 +91,7 @@ async function handleForums(event) {
const name = computeName(event) const name = computeName(event)
//@ts-ignore the presence of message:{} and the absence of type:11 - that's intended for threads in Forum channels (*and no, createThreadWithMessage wouldn't work here, either - that one takes an ALREADY EXISTING message ID, whereas this needs a new message) //@ts-ignore the presence of message:{} and the absence of type:11 - that's intended for threads in Forum channels (*and no, createThreadWithMessage wouldn't work here, either - that one takes an ALREADY EXISTING message ID, whereas this needs a new message)
console.log(discord.channels.get(channelID)?.flags)
await discord.snow.channel.createThreadWithoutMessage(channelID, {name: name.name, message:{content:"heyy~"}}) await discord.snow.channel.createThreadWithoutMessage(channelID, {name: name.name, message:{content:"heyy~"}})
if (!name.truncated) api.redactEvent(event.room_id, event.event_id) //Don't destroy people's texts - only remove if no truncation is guaranteed. if (!name.truncated) api.redactEvent(event.room_id, event.event_id) //Don't destroy people's texts - only remove if no truncation is guaranteed.
return true return true