Old copypaste fail - we were returning the most recent user id when creating channels
(Database.py)
This commit is contained in:
parent
20d75e9716
commit
1d807fefe0
1 changed files with 1 additions and 1 deletions
|
@ -39,7 +39,7 @@ class Channels(Table):
|
||||||
(server_id, name) VALUES (?, ?)""",
|
(server_id, name) VALUES (?, ?)""",
|
||||||
[server_id, name.lower()])
|
[server_id, name.lower()])
|
||||||
return self.database.execute_fetchone(
|
return self.database.execute_fetchone(
|
||||||
"SELECT user_id FROM users ORDER BY user_id DESC LIMIT 1")[0]
|
"SELECT channel_id FROM channels ORDER BY channel_id DESC LIMIT 1")[0]
|
||||||
def delete(self, channel_id: int):
|
def delete(self, channel_id: int):
|
||||||
self.database.execute("DELETE FROM channels WHERE channel_id=?",
|
self.database.execute("DELETE FROM channels WHERE channel_id=?",
|
||||||
[channel_id])
|
[channel_id])
|
||||||
|
|
Loading…
Reference in a new issue