Fix __init__ to support discord.py forks

This commit is contained in:
cloudwithax 2021-12-06 17:58:21 -05:00
parent d1d2463680
commit 50429277ea
1 changed files with 4 additions and 4 deletions

View File

@ -1,14 +1,14 @@
"""Pomice wrapper for Lavalink, made possible by cloudwithax 2021""" """Pomice wrapper for Lavalink, made possible by cloudwithax 2021"""
import discord import discord
if discord.__version__ != "2.0.0a": if not discord.__version__.startswith("2.0"):
class DiscordPyOutdated(Exception): class DiscordPyOutdated(Exception):
pass pass
raise DiscordPyOutdated( raise DiscordPyOutdated(
"You must have discord.py 2.0 to use this library. " "You must have discord.py 2.0 or a discord.py fork that uses the 'discord' namespace "
"Uninstall your current version and install discord.py 2.0 " "(a.k.a: you import the libary using 'import discord') to use this library. "
"using 'pip install git+https://github.com/Rapptz/discord.py@master'" "Uninstall your current version and install discord.py 2.0 or a compatible fork."
) )
__version__ = "1.1.6" __version__ = "1.1.6"