Add permissions to channel owner

This commit is contained in:
Sam 2023-07-29 19:59:45 +01:00
parent cda96768e5
commit 39f6bcccea

View File

@ -1,9 +1,7 @@
import discord
import asyncio
from discord.ext import commands
import traceback
import sqlite3
import validators
class voice(commands.Cog):
@ -59,6 +57,7 @@ class voice(commands.Cog):
channelID = channel2.id
await member.move_to(channel2)
await channel2.set_permissions(self.bot.user, connect=True,read_messages=True)
await channel2.set_permissions(member, connect=True,read_messages=True)
await channel2.edit(name= name, user_limit = limit)
c.execute("INSERT INTO voiceChannel VALUES (?, ?)", (id,channelID))
conn.commit()