mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-24 08:08:15 -05:00
🐛Fix analytics dashboard date oboe
This commit is contained in:
parent
29892a9619
commit
5ca68ff682
1 changed files with 1 additions and 1 deletions
|
@ -4,7 +4,7 @@ module.exports.createContiguousDays = (timeframeDays, skipToday=true) ->
|
|||
# Return list of last 'timeframeDays' contiguous days in yyyy-mm-dd format
|
||||
days = []
|
||||
currentDate = new Date()
|
||||
currentDate.setUTCDate(currentDate.getUTCDate() - timeframeDays)
|
||||
currentDate.setUTCDate(currentDate.getUTCDate() - timeframeDays + 1)
|
||||
currentDate.setUTCDate(currentDate.getUTCDate() - 1) if skipToday
|
||||
for i in [0...timeframeDays]
|
||||
currentDay = currentDate.toISOString().substr(0, 10)
|
||||
|
|
Loading…
Reference in a new issue