From 810b994af25cf34bd799ddcb6b7fb6dc3e72f797 Mon Sep 17 00:00:00 2001 From: DL6ER Date: Tue, 3 Jan 2017 14:59:37 +0100 Subject: [PATCH] Fix IE support for main page (untested). Has been broken because codacy enforces Object Literal Shorthand Syntax --- scripts/pi-hole/js/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/pi-hole/js/index.js b/scripts/pi-hole/js/index.js index 3eec3bea..0edfc22b 100644 --- a/scripts/pi-hole/js/index.js +++ b/scripts/pi-hole/js/index.js @@ -291,7 +291,7 @@ $(document).ready(function() { enabled: true, mode: "x-axis", callbacks: { - title(tooltipItem, data) { + title: function(tooltipItem, data){ var label = tooltipItem[0].xLabel; var time = label.match(/(\d?\d):?(\d?\d?)/); var h = parseInt(time[1], 10); @@ -300,7 +300,7 @@ $(document).ready(function() { var to = padNumber(h)+":"+padNumber(m+9)+":59"; return "Queries from "+from+" to "+to; }, - label(tooltipItems, data) { + label: function(tooltipItems, data) { if(tooltipItems.datasetIndex === 1) { var percentage = 0.0;