mirror of
https://github.com/SamSanai/VoiceMaster-Discord-Bot.git
synced 2024-11-21 17:38:14 +01:00
Add permissions to channel owner
This commit is contained in:
parent
cda96768e5
commit
39f6bcccea
@ -1,9 +1,7 @@
|
|||||||
import discord
|
import discord
|
||||||
import asyncio
|
import asyncio
|
||||||
from discord.ext import commands
|
from discord.ext import commands
|
||||||
import traceback
|
|
||||||
import sqlite3
|
import sqlite3
|
||||||
import validators
|
|
||||||
|
|
||||||
|
|
||||||
class voice(commands.Cog):
|
class voice(commands.Cog):
|
||||||
@ -59,6 +57,7 @@ class voice(commands.Cog):
|
|||||||
channelID = channel2.id
|
channelID = channel2.id
|
||||||
await member.move_to(channel2)
|
await member.move_to(channel2)
|
||||||
await channel2.set_permissions(self.bot.user, connect=True,read_messages=True)
|
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)
|
await channel2.edit(name= name, user_limit = limit)
|
||||||
c.execute("INSERT INTO voiceChannel VALUES (?, ?)", (id,channelID))
|
c.execute("INSERT INTO voiceChannel VALUES (?, ?)", (id,channelID))
|
||||||
conn.commit()
|
conn.commit()
|
||||||
|
Loading…
Reference in New Issue
Block a user