mirror of
https://github.com/Matthww/TuneBot.git
synced 2026-09-21 19:57:48 +00:00
Merge branch 'dev' into command-description-config
This commit is contained in:
+2
-4
@@ -12,6 +12,7 @@ from bot import ChristmasBot
|
||||
from utils.EmbedGenerator import EmbedGenerator
|
||||
from utils.classes import BaseCog
|
||||
from utils.paginator import HelpPaginator
|
||||
from utils.database import AutoJoin
|
||||
|
||||
|
||||
class InformationCog(BaseCog, name="Information"):
|
||||
@@ -69,10 +70,7 @@ class InformationCog(BaseCog, name="Information"):
|
||||
f"Server Uptime: `{datetime.timedelta(milliseconds=node.stats.uptime)}`"
|
||||
)
|
||||
await ctx.send(fmt)
|
||||
|
||||
from utils import database
|
||||
|
||||
database.AutoJoin.get_channels()
|
||||
AutoJoin.get_channels()
|
||||
|
||||
@commands.command(name="help", aliases=["about", "info"])
|
||||
@commands.cooldown(1, 1, commands.BucketType.user)
|
||||
|
||||
+3
-6
@@ -16,6 +16,8 @@ from utils.database import AutoJoin
|
||||
from context import CustomContext
|
||||
from discord import Embed
|
||||
|
||||
from utils.database import Playlist
|
||||
|
||||
url_rx = re.compile(r"https?://(?:www\.)?.+")
|
||||
|
||||
|
||||
@@ -105,12 +107,7 @@ class Music(BaseCog):
|
||||
await textchannel.send("Automatically joined the voice channel")
|
||||
|
||||
async def fill_player_queue(self, player: DefaultPlayer, buffer: Optional[int] = 1):
|
||||
pipeline = self.bot._redis_client.pipeline()
|
||||
for _ in range(buffer):
|
||||
pipeline.randomkey()
|
||||
|
||||
queries = await pipeline.execute()
|
||||
print(queries)
|
||||
queries = await Playlist.random(self.bot._redis_client, buffer)
|
||||
# Get the results for the query from Lavalink.
|
||||
for query in queries:
|
||||
result = await player.node.get_tracks(query)
|
||||
|
||||
Reference in New Issue
Block a user