prompt for lunch only until expected lunch time

This commit is contained in:
2025-07-30 13:39:37 +02:00
parent ccb9c06f98
commit 84a2a94064

View File

@@ -78,7 +78,9 @@ public class LoadingBar {
var br = new BufferedReader(new InputStreamReader(System.in, StandardCharsets.UTF_8));
print("Ankunftszeit: ");
var startTime = LocalTime.parse(br.readLine(), TIME_FORMATTER).truncatedTo(ChronoUnit.MINUTES);
handleMittagspause(br, startTime);
if (startTime.until(LocalTime.now(), ChronoUnit.MINUTES) < DEFAULT_NUMBER_WORK_MINS_BEFORE_LUNCH) {
handleMittagspause(br, startTime);
}
handleZapfenstreich(br, startTime);
}