a
This commit is contained in:
@@ -24,7 +24,10 @@ CREATE TABLE IF NOT EXISTS val (
|
|||||||
default_time TEXT NOT NULL DEFAULT '21:00'
|
default_time TEXT NOT NULL DEFAULT '21:00'
|
||||||
)
|
)
|
||||||
""")
|
""")
|
||||||
cursor.execute("INSERT INTO val (default_time) VALUES (?)", ('21:00',))
|
cursor.execute("SELECT COUNT(*) FROM val")
|
||||||
|
count = cursor.fetchone()[0]
|
||||||
|
if count == 0:
|
||||||
|
cursor.execute("INSERT INTO val (default_time) VALUES (?)", ('21:00',))
|
||||||
conn.commit()
|
conn.commit()
|
||||||
conn.close()
|
conn.close()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user