mirror of
https://github.com/nexy7574/LCC-bot.git
synced 2024-09-19 18:16:34 +01:00
Fix database
This commit is contained in:
parent
84fdd21a9d
commit
8c2f671e42
1 changed files with 2 additions and 3 deletions
|
@ -11,7 +11,7 @@ from discord.ext import commands
|
||||||
|
|
||||||
class McDataBase:
|
class McDataBase:
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.db = pathlib.Path.home() / ".cache" / "McDataBase.db"
|
self.db = pathlib.Path.home() / ".cache" / "lcc-bot" / "McDataBase.db"
|
||||||
self._conn: typing.Optional[aiosqlite.Connection] = None
|
self._conn: typing.Optional[aiosqlite.Connection] = None
|
||||||
|
|
||||||
async def init_db(self):
|
async def init_db(self):
|
||||||
|
@ -21,8 +21,7 @@ class McDataBase:
|
||||||
"""
|
"""
|
||||||
CREATE TABLE IF NOT EXISTS breaks (
|
CREATE TABLE IF NOT EXISTS breaks (
|
||||||
user_id INTEGER PRIMARY KEY,
|
user_id INTEGER PRIMARY KEY,
|
||||||
since FLOAT NOT NULL,
|
since FLOAT NOT NULL
|
||||||
author INTEGER NOT NULL
|
|
||||||
);
|
);
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue