diff --git a/lib/Comands.py b/lib/Comands.py index 5c9672a..30ae769 100644 --- a/lib/Comands.py +++ b/lib/Comands.py @@ -22,7 +22,7 @@ async def read_json(guild: int, _param: str): Reads Json file to determite config strings :param guild: ID of Guild :param _param: Parameter in json file - :return: value of parameter + :return: value of parameter. """ with open('prefix.json', 'r', encoding='utf-8') as fp: # Open the JSON parameter = None diff --git a/lib/DB.py b/lib/DB.py index f66dd29..3e506e0 100644 --- a/lib/DB.py +++ b/lib/DB.py @@ -39,11 +39,11 @@ async def fill_bd(name: str, userid: int, isbot: bool, nick: str, guild: int): async def add_audio(guild: int, user: int, audio: str, track: str = 'usertracks'): """ - Adding audio into folder and DB + Adding audio into а folder and DB :param guild: Guild id :param user: :param audio: - :param track: usertracks or defaulttracks + :param track: usertracks or defaulttracks. """ # audio = f'{DB.read_db(guild, user, track)}, {audio}' sql_update_query = f"""UPDATE "{guild}" set {track} = ? where userid = ?""" diff --git a/main.py b/main.py index b3e4f5a..b4ae973 100644 --- a/main.py +++ b/main.py @@ -13,9 +13,7 @@ threading.current_thread().name = "main" logging.basicConfig(stream=sys.stdout, filemode='w', level='INFO', format='%(asctime)s - %(levelname)s - %(threadName)s - %(message)s') - -intents = disnake.Intents.default() -intents.members = True +intents = disnake.Intents(members=True) bot = commands.Bot(command_prefix='$', guild_subscriptions=True, intents=intents) f = [] for filenames in walk('audio'):