Update modules/sqlite_local.py
All checks were successful
/ check (push) Successful in 12s

This commit is contained in:
Nova Cat 2025-01-21 19:57:54 -08:00
parent 692960076d
commit 8865303d0c

View file

@ -8,7 +8,7 @@ class broker:
if not os.path.isfile(data_path):
print("Creating database file...")
open(data_path, "w").write("")
self.conn = sqlite3.connect(data_path)
self.conn = sqlite3.connect(data_path, check_same_thread=False)
self.fnet = Fernet(fernet_key)
db = self.conn.cursor()
db.execute("""CREATE table IF NOT EXISTS bans (ip varchar(255), reason varchar(255))""")