Wrap Update at correct level
This commit is contained in:
parent
153f55f7b0
commit
c4b68a8c2f
@ -21,11 +21,11 @@ def index():
|
|||||||
if current_cycle['end_time'] is None:
|
if current_cycle['end_time'] is None:
|
||||||
cycle_length = (pendulum.now() - start_time).days
|
cycle_length = (pendulum.now() - start_time).days
|
||||||
|
|
||||||
db.execute(
|
db.execute(
|
||||||
'UPDATE cycle SET cycle_length = ?'
|
'UPDATE cycle SET cycle_length = ?'
|
||||||
' WHERE id = ?',
|
' WHERE id = ?',
|
||||||
(cycle_length, current_cycle['id'])
|
(cycle_length, current_cycle['id'])
|
||||||
)
|
)
|
||||||
|
|
||||||
cycles = db.execute(
|
cycles = db.execute(
|
||||||
'SELECT id, start_time, end_time, cycle_length'
|
'SELECT id, start_time, end_time, cycle_length'
|
||||||
|
Loading…
Reference in New Issue
Block a user