refactor code

This commit is contained in:
hibiki
2021-07-30 21:21:51 +08:00
parent 2ad891aa1e
commit cc24822dca
165 changed files with 7815 additions and 8174 deletions
-2
View File
@@ -1,5 +1,4 @@
from gino import Gino
from .log import logger
from configs.config import bind, sql_name, user, password, address, port, database
@@ -14,7 +13,6 @@ async def init():
i_bind = DATABASE_URI if DATABASE_URI else bind
if not i_bind:
i_bind = f"{sql_name}://{user}:{password}@{address}:{port}/{database}"
# print(i_bind)
try:
await db.set_bind(i_bind)
await db.gino.create_all()