fixed 24h bug

This commit is contained in:
Manuel Friedli 2014-06-28 23:46:12 +02:00
parent 348177e52a
commit 340669c5eb
5 changed files with 6 additions and 5 deletions

View File

@ -1,5 +1,5 @@
CACHE MANIFEST
# 6.2
# 6.2.1
COPYING
README.md

View File

@ -71,7 +71,7 @@ var layout = {
"getHour": function(date) {
var hour = date.getHours();
if (date.getMinutes() >= 35) {
return hour + 1;
return (hour + 1) % 24;
}
return hour;
}

View File

@ -1,3 +1,4 @@
/*
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@ -72,7 +73,7 @@ var layout = {
"getHour": function(date) {
var hour = date.getHours();
if (date.getMinutes() >= 35) {
return hour + 1;
return (hour + 1) % 24;
}
return hour;
}

View File

@ -70,7 +70,7 @@ var layout = {
"getHour": function(date) {
var hour = date.getHours();
if (date.getMinutes() >= 35) {
return hour + 1;
return (hour + 1) % 24;
}
return hour;
}

2
uhr.js
View File

@ -175,7 +175,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
}
var hour = date.getHours();
if (date.getMinutes() >= 25) {
return hour + 1;
return (hour + 1) % 24;
}
return hour;
},