Permalink
Browse files

Fix off-by-one

  • Loading branch information...
alisdair committed Jun 22, 2015
1 parent 238efdc commit 6e293d074a03f95834a68de6e44a1b35046a1df8
Showing with 1 addition and 6 deletions.
  1. +1 −6 app/components/timezone-collection.js
@@ -15,12 +15,7 @@ function calculateTimezoneStart(offset) {
}

function calculateTimezoneStop(offset) {
// Finds the end of the hour window for the timezone containing offset.
// 7200 -> 7200
// 9000 -> 10800
// -7200 -> -7200
// -9000 -> -7200
return Math.ceil(offset / secondsInHour) * secondsInHour;
return calculateTimezoneStart(offset) + secondsInHour;
}

function nextTimezone(start) {

0 comments on commit 6e293d0

Please sign in to comment.