mirror of https://github.com/snachodog/mybuddy.git
Fix KeyError at /children/x/reports/sleep/pattern/
This commit is contained in:
parent
767dac44f4
commit
1d5780154e
|
@ -190,6 +190,8 @@ def _add_adjustment(adjustment, days):
|
|||
:param blocks: List of days
|
||||
"""
|
||||
column = adjustment.pop("column")
|
||||
if not column in days:
|
||||
days[column] = []
|
||||
# Fake (0) entry to keep the color switching logic working.
|
||||
days[column].append({"time": 0, "label": 0})
|
||||
|
||||
|
|
Loading…
Reference in New Issue