mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
fixed (?) db.py
blame steffo if something breaks
This commit is contained in:
parent
c1f0f34aa8
commit
e903c6484f
1 changed files with 2 additions and 2 deletions
4
db.py
4
db.py
|
@ -16,7 +16,7 @@ import re
|
|||
import enum
|
||||
# Both packages have different pip names
|
||||
# noinspection PyPackageRequirements
|
||||
from discord import User as DiscordUser
|
||||
# from discord import User as DiscordUser
|
||||
# noinspection PyPackageRequirements
|
||||
from telegram import User as TelegramUser
|
||||
import loldata
|
||||
|
@ -689,7 +689,7 @@ class Discord(Base, Mini):
|
|||
return f"<db.Discord {self.discord_id}>"
|
||||
|
||||
@staticmethod
|
||||
def create(session: Session, royal_username, discord_user: DiscordUser):
|
||||
def create(session: Session, royal_username, discord_user: "DiscordUser"):
|
||||
d = session.query(Discord).filter(Discord.discord_id == discord_user.id).first()
|
||||
if d is not None:
|
||||
raise AlreadyExistingError(repr(d))
|
||||
|
|
Loading…
Reference in a new issue