Fix missing cast for the before var

This commit is contained in:
2017-03-17 11:41:00 +01:00
parent 7472cf2b16
commit 56b5c89edf

View File

@@ -47,7 +47,7 @@ def index(before: int=0):
# TODO: Implement project-level metrics (and update ad every child update)
if before:
before = datetime.datetime.strptime(before, '%Y%m%d')
before = datetime.datetime.strptime(str(before), '%Y%m%d')
else:
today = datetime.date.today()
before = datetime.datetime(today.year, today.month, today.day)