# Buggy code
async def _eq_save(self, ctx: commands.Context, eq_preset: str = None):
    """Save the current eq settings to a preset."""
    if not self._player_check(ctx):
        return await self._embed_msg(ctx, _("Nothing playing."))
    dj_enabled = await self.config.guild(ctx.guild).dj_enabled()
    if dj_enabled:
        if not await self._can_instaskip(ctx, ctx.author):
            return await self._embed_msg(
                ctx, _("You need the DJ role to save equalizer presets.")
            )
    if not eq_preset:
        await self._embed_msg(ctx, _("Please enter a name for this equalizer preset."))
        try:
            eq_name_msg = await ctx.bot.wait_for(
                "message",
                timeout=15.0,
                check=MessagePredicate.regex(rf"^(?!{re.escape(ctx.prefix)})", ctx),
            )
            eq_preset = eq_name_msg.content.split(" ")[0].strip('"').lower()
        except asyncio.TimeoutError:
            return await self._embed_msg(
                ctx, _("No equalizer preset name entered, try the command again later.")
            )

    eq_exists_msg = None
    eq_preset = eq_preset.lower().lstrip(ctx.prefix)
    eq_presets = await self.config.custom("EQUALIZER", ctx.guild.id).eq_presets()
    eq_list = list(eq_presets.keys())

    if len(eq_preset) > 20:
        return await self._embed_msg(
            ctx, _("Try the command again with a shorter name.")
        )
    if eq_preset in eq_list:
        embed = discord.Embed(
            colour=await ctx.embed_colour(),
            title=_("Preset name already exists, do you want to replace it?"),
        )
        eq_exists_msg = await ctx.send(embed=embed)
        start_adding_reactions(eq_exists_msg, ReactionPredicate.YES_OR_NO_EMOJIS)
        pred = ReactionPredicate.yes_or_no(eq_exists_msg, ctx.author)
        await ctx.bot.wait_for("reaction_add", check=pred)
        if not pred.result:
            await self._clear_react(eq_exists_msg)
            embed2 = discord.Embed(
                colour=await ctx.embed_colour(), title=_("Not saving preset.")
            )
            return await eq_exists_msg.edit(embed=embed2)

    player = lavalink.get_player(ctx.guild.id)
    eq = player.fetch("eq", Equalizer())
    to_append = {eq_preset: {"author": ctx.author.id, "bands": eq.bands}}
    new_eq_presets = {**eq_presets, **to_append}
    await self.config.custom("EQUALIZER", ctx.guild.id).eq_presets.set(new_eq_presets)
    embed3 = discord.Embed(
        colour=await ctx.embed_colour(),
        title=_(
            "Current equalizer saved to the {preset_name} preset.".format(
                preset_name=eq_preset
            )
        ),
    )
    if eq_exists_msg:
        await self._clear_react(eq_exists_msg)
        await eq_exists_msg.edit(embed=embed3)
    else:
        await ctx.send(embed=embed3)


# Traceback (RuntimeError)
Traceback (most recent call last):
File "/home/martinebots/martinebotsvenv/lib/python3.7/site-packages/discord/ext/commands/core.py", line 79, in wrapped
ret = await coro(*args, **kwargs)
File "/home/martinebots/martinebotscogs/cogs_modified/audio/audio.py", line 3183, in play
await self._enqueue_tracks(ctx, query)
File "/home/martinebots/martinebotscogs/cogs_modified/audio/audio.py", line 3885, in _enqueue_tracks
result, called_api = await self.music_cache.lavalink_query(ctx, player, query)
File "/home/martinebots/martinebotscogs/cogs_modified/audio/apis.py", line 911, in lavalink_query
results = await player.load_tracks(query)
File "/home/martinebots/martinebotsvenv/lib/python3.7/site-packages/lavalink/rest_api.py", line 300, in load_tracks
self.__check_node_ready()
File "/home/martinebots/martinebotsvenv/lib/python3.7/site-packages/lavalink/rest_api.py", line 268, in __check_node_ready
raise RuntimeError("Cannot execute REST request when node not ready.")
RuntimeError: Cannot execute REST request when node not ready.

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/home/martinebots/martinebotsvenv/lib/python3.7/site-packages/discord/ext/commands/bot.py", line 863, in invoke
await ctx.command.invoke(ctx)
File "/home/martinebots/martinebotsvenv/lib/python3.7/site-packages/discord/ext/commands/core.py", line 728, in invoke
await injected(*ctx.args, **ctx.kwargs)
File "/home/martinebots/martinebotsvenv/lib/python3.7/site-packages/discord/ext/commands/core.py", line 88, in wrapped
raise CommandInvokeError(exc) from exc
discord.ext.commands.errors.CommandInvokeError: Command raised an exception: RuntimeError: Cannot execute REST request when node not ready.```

# Fixed code
async def _eq_save(self, ctx: commands.Context, eq_preset: str = None):
    """Save the current eq settings to a preset."""
    if not self._player_check(ctx):
        return await self._embed_msg(ctx, title=_("Nothing playing."))
    dj_enabled = self._dj_status_cache.setdefault(
        ctx.guild.id, await self.config.guild(ctx.guild).dj_enabled()
    )
    if dj_enabled:
        if not await self._can_instaskip(ctx, ctx.author):
            ctx.command.reset_cooldown(ctx)
            return await self._embed_msg(
                ctx,
                title=_("Unable To Save Preset"),
                description=_("You need the DJ role to save equalizer presets."),
            )
    if not eq_preset:
        await self._embed_msg(
            ctx, title=_("Please enter a name for this equalizer preset.")
        )
        try:
            eq_name_msg = await ctx.bot.wait_for(
                "message",
                timeout=15.0,
                check=MessagePredicate.regex(rf"^(?!{re.escape(ctx.prefix)})", ctx),
            )
            eq_preset = eq_name_msg.content.split(" ")[0].strip('"').lower()
        except asyncio.TimeoutError:
            ctx.command.reset_cooldown(ctx)
            return await self._embed_msg(
                ctx,
                title=_("Unable To Save Preset"),
                description=_(
                    "No equalizer preset name entered, try the command again later."
                ),
            )

    eq_exists_msg = None
    eq_preset = eq_preset.lower().lstrip(ctx.prefix)
    eq_presets = await self.config.custom("EQUALIZER", ctx.guild.id).eq_presets()
    eq_list = list(eq_presets.keys())

    if len(eq_preset) > 20:
        ctx.command.reset_cooldown(ctx)
        return await self._embed_msg(
            ctx,
            title=_("Unable To Save Preset"),
            description=_("Try the command again with a shorter name."),
        )
    if eq_preset in eq_list:
        eq_exists_msg = await self._embed_msg(
            ctx, title=_("Preset name already exists, do you want to replace it?")
        )
        start_adding_reactions(eq_exists_msg, ReactionPredicate.YES_OR_NO_EMOJIS)
        pred = ReactionPredicate.yes_or_no(eq_exists_msg, ctx.author)
        await ctx.bot.wait_for("reaction_add", check=pred)
        if not pred.result:
            await self._clear_react(eq_exists_msg)
            embed2 = discord.Embed(
                colour=await ctx.embed_colour(), title=_("Not saving preset.")
            )
            ctx.command.reset_cooldown(ctx)
            return await eq_exists_msg.edit(embed=embed2)

    player = lavalink.get_player(ctx.guild.id)
    eq = player.fetch("eq", Equalizer())
    to_append = {eq_preset: {"author": ctx.author.id, "bands": eq.bands}}
    new_eq_presets = {**eq_presets, **to_append}
    await self.config.custom("EQUALIZER", ctx.guild.id).eq_presets.set(new_eq_presets)
    embed3 = discord.Embed(
        colour=await ctx.embed_colour(),
        title=_(
            "Current equalizer saved to the {preset_name} preset.".format(
                preset_name=eq_preset
            )
        ),
    )
    if eq_exists_msg:
        await self._clear_react(eq_exists_msg)
        await eq_exists_msg.edit(embed=embed3)
    else:
        await self._embed_msg(ctx, embed=embed3)