From 3e6d51fc5a7c3daec1e66a80768b85562f4f8e14 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Wed, 24 May 2017 21:18:23 -0400 Subject: [PATCH] fixes #5606 :rage2: --- public/src/admin/general/dashboard.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/public/src/admin/general/dashboard.js b/public/src/admin/general/dashboard.js index 054ed54e51..6b544ae29c 100644 --- a/public/src/admin/general/dashboard.js +++ b/public/src/admin/general/dashboard.js @@ -297,7 +297,9 @@ define('admin/general/dashboard', ['semver', 'Chart', 'translator'], function (s $('[data-action="updateGraph"]:not([data-units="custom"])').on('click', function () { var until = new Date(); var amount = $(this).attr('data-amount'); - until.setHours(0, 0, 0, 0); + if ($(this).attr('data-units') === 'days') { + until.setHours(0, 0, 0, 0); + } until = until.getTime(); updateTrafficGraph($(this).attr('data-units'), until, amount); $('[data-action="updateGraph"]').removeClass('active');