From ad6dc6e24c85eeb913a303008f611f8518f8db25 Mon Sep 17 00:00:00 2001 From: Adam Harrison Date: Thu, 21 Dec 2017 17:56:07 +0000 Subject: [PATCH] Use US/Eastern time instead of UTC --- .../conversion/validate/CpcClinicalDocumentValidator.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/converter/src/main/java/gov/cms/qpp/conversion/validate/CpcClinicalDocumentValidator.java b/converter/src/main/java/gov/cms/qpp/conversion/validate/CpcClinicalDocumentValidator.java index 068235d2a..a09ba69a1 100644 --- a/converter/src/main/java/gov/cms/qpp/conversion/validate/CpcClinicalDocumentValidator.java +++ b/converter/src/main/java/gov/cms/qpp/conversion/validate/CpcClinicalDocumentValidator.java @@ -2,6 +2,7 @@ import java.time.Clock; import java.time.LocalDate; +import java.time.ZoneId; import com.google.common.base.Strings; @@ -24,8 +25,8 @@ public class CpcClinicalDocumentValidator extends NodeValidator { static final String END_DATE_VARIABLE = "CPC_END_DATE"; private static final String NEVER_ENDING = "3000-01-01"; // LocalDate.now() creates extra unneeded clock objects before Java 9. - // It also uses the system clock, rather than UTC. - private static final Clock CLOCK = Clock.systemUTC(); + // It also uses the system clock, rather than Eastern Time. + private static final Clock CLOCK = Clock.system(ZoneId.of("US/Eastern")); /** * Validates a single clinical document node @@ -80,7 +81,7 @@ private void validateSubmissionDate(Node node) { } /** - * @return the current local date, in UTC + * @return the current local date, in Eastern Time */ private LocalDate now() { return LocalDate.now(CLOCK);