diff --git a/js/Date.js b/js/Date.js index c4d703ef..35815a52 100644 --- a/js/Date.js +++ b/js/Date.js @@ -97,7 +97,7 @@ Flotr.Date = { ticks = [], tickSize = axis.tickSize, tickUnit, - formatter, i; + formatter, i ,d; // Use custom formatter or time tick formatter formatter = (options.tickFormatter === Flotr.defaultTickFormatter ? @@ -105,7 +105,7 @@ Flotr.Date = { ); for (i = 0; i < spec.length - 1; ++i) { - var d = spec[i][0] * timeUnits[spec[i][1]]; + d = spec[i][0] * timeUnits[spec[i][1]]; if (delta < (d + spec[i+1][0] * timeUnits[spec[i+1][1]]) / 2 && d >= tickSize) break; } @@ -127,7 +127,7 @@ Flotr.Date = { axis.tickSize = tickSize; var step = tickSize * timeUnits[tickUnit]; - var d = new Date(min); + d = new Date(min); function setTick (name) { set(d, name, mode, Flotr.floorInBase(