WIP: feature: threads'n'forums #74
2 changed files with 2 additions and 2 deletions
|
|
@ -195,7 +195,7 @@ async function channelToKState(channel, guild, di) {
|
|||
if (hasCustomTopic) delete channelKState["m.room.topic/"]
|
||||
|
||||
// Make voice channels be a Matrix voice room (MSC3417)
|
||||
if (channel.type === DiscordTypes.ChannelType.GuildVoice) {
|
||||
if (channel.type === DiscordTypes.ChannelType.GuildVoice || channel.type === DiscordTypes.ChannelType.GuildStageVoice) {
|
||||
creationContent.type = "org.matrix.msc3417.call"
|
||||
channelKState["org.matrix.msc3401.call/"] = {
|
||||
"m.intent": "m.room",
|
||||
|
|
|
|||
|
|
@ -112,7 +112,7 @@ function getChannelRoomsLinks(guild, rooms, roles) {
|
|||
let unlinkedChannelIDs = channelIDs.filter(c => !linkedChannelIDs.includes(c))
|
||||
/** @type {DiscordTypes.APIGuildChannel[]} */ // @ts-ignore
|
||||
let unlinkedChannels = unlinkedChannelIDs.map(c => discord.channels.get(c))
|
||||
let removedWrongTypeChannels = dUtils.filterTo(unlinkedChannels, c => c && [0, 5].includes(c.type))
|
||||
let removedWrongTypeChannels = dUtils.filterTo(unlinkedChannels, c => c && [0, 2, 5, 13, 15, 16].includes(c.type))
|
||||
let removedPrivateChannels = dUtils.filterTo(unlinkedChannels, c => {
|
||||
const permissions = dUtils.getPermissions(guild.id, roles, guild.roles, botID, c["permission_overwrites"])
|
||||
return dUtils.hasSomePermissions(permissions, ["Administrator", "ViewChannel"])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue