Fix opening day

This commit is contained in:
PavelRatushny 2017-12-08 18:41:10 +02:00
parent d9b4a213c9
commit 5a73860d07

View file

@ -217,6 +217,7 @@ public class OpeningHoursParser {
Calendar cal = (Calendar) calendar.clone();
String openingTime = "";
for (int i = 0; i < 7; i++) {
cal.add(Calendar.DAY_OF_MONTH, 1);
for (OpeningHoursRule r : rules) {
if (r.containsDay(cal) && r.containsMonth(cal)) {
openingTime = r.getTime(cal, false, -1, true);
@ -225,8 +226,6 @@ public class OpeningHoursParser {
if (!Algorithms.isEmpty(openingTime)) {
openingTime += " " + localDaysStr[cal.get(Calendar.DAY_OF_WEEK)];
break;
} else {
cal.add(Calendar.DAY_OF_MONTH, 1);
}
}
return openingTime;