From ec0d7bd96f29fbf498af1233528b3aaa2a07cc6b Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Sat, 7 Nov 2020 19:14:13 +0100 Subject: [PATCH] Bug Fixed --- .../Superalgos/Spaces/Charting-Space/Plotting/Plotter.js | 2 +- Projects/Superalgos/Utilities/Dates.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Projects/Superalgos/Spaces/Charting-Space/Plotting/Plotter.js b/Projects/Superalgos/Spaces/Charting-Space/Plotting/Plotter.js index d4795e122..7b2690b6e 100644 --- a/Projects/Superalgos/Spaces/Charting-Space/Plotting/Plotter.js +++ b/Projects/Superalgos/Spaces/Charting-Space/Plotting/Plotter.js @@ -418,7 +418,7 @@ function newPlotter() { records = [] while (currentDate.valueOf() <= farRightDate.valueOf() + ONE_DAY_IN_MILISECONDS) { - let stringDate = currentDate.getFullYear() + '-' + pad(currentDate.getMonth() + 1, 2) + '-' + pad(currentDate.getDate(), 2) + let stringDate = currentDate.getUTCFullYear() + '-' + pad(currentDate.getUTCMonth() + 1, 2) + '-' + pad(currentDate.getUTCDate(), 2) let dailyFile = fileCursor.files.get(stringDate) diff --git a/Projects/Superalgos/Utilities/Dates.js b/Projects/Superalgos/Utilities/Dates.js index 2a406c2cb..44dad69c4 100644 --- a/Projects/Superalgos/Utilities/Dates.js +++ b/Projects/Superalgos/Utilities/Dates.js @@ -7,9 +7,9 @@ function newSuperalgosUtilitiesDates() { function formatDate(date) { var d = new Date(date), - month = '' + (d.getMonth() + 1), - day = '' + d.getDate(), - year = d.getFullYear(); + month = '' + (d.getUTCMonth() + 1), + day = '' + d.getUTCDate(), + year = d.getUTCFullYear(); if (month.length < 2) month = '0' + month;