From 896411abfb9c19806fddcc05aad54f63ea0f359e Mon Sep 17 00:00:00 2001 From: Chip Kent Date: Tue, 16 Jan 2024 09:04:33 -0700 Subject: [PATCH] Responding to review comments. --- .../time/calendar/BusinessCalendarXMLParser.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/engine/time/src/main/java/io/deephaven/time/calendar/BusinessCalendarXMLParser.java b/engine/time/src/main/java/io/deephaven/time/calendar/BusinessCalendarXMLParser.java index 15b2dfcf9c0..14c3a133593 100644 --- a/engine/time/src/main/java/io/deephaven/time/calendar/BusinessCalendarXMLParser.java +++ b/engine/time/src/main/java/io/deephaven/time/calendar/BusinessCalendarXMLParser.java @@ -125,13 +125,13 @@ private static BusinessCalendarInputs parseBusinessCalendarInputs(@NotNull final calendarElements.description = getText(root.getChild("description")); calendarElements.holidays = parseHolidays(root, calendarElements.timeZone); final String firstValidDateStr = getText(root.getChild("firstValidDate")); - calendarElements.firstValidDate = DateTimeUtils.parseLocalDate( - firstValidDateStr == null ? Collections.min(calendarElements.holidays.keySet()).toString() - : firstValidDateStr); + calendarElements.firstValidDate = + firstValidDateStr == null ? Collections.min(calendarElements.holidays.keySet()) + : DateTimeUtils.parseLocalDate(firstValidDateStr); final String lastValidDateStr = getText(root.getChild("lastValidDate")); - calendarElements.lastValidDate = DateTimeUtils.parseLocalDate( - lastValidDateStr == null ? Collections.max(calendarElements.holidays.keySet()).toString() - : lastValidDateStr); + calendarElements.lastValidDate = + lastValidDateStr == null ? Collections.max(calendarElements.holidays.keySet()) + : DateTimeUtils.parseLocalDate(lastValidDateStr); // Set the default values final Element defaultElement = getRequiredChild(root, "default");