From 99278207ae3ac68cc3d050018daad61b0bfc5f03 Mon Sep 17 00:00:00 2001 From: atuonufure Date: Thu, 11 Jan 2024 03:35:58 +0100 Subject: [PATCH] Update timebase equals --- fhirpathpy/engine/nodes.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/fhirpathpy/engine/nodes.py b/fhirpathpy/engine/nodes.py index 6ab1d0d..93d9360 100644 --- a/fhirpathpy/engine/nodes.py +++ b/fhirpathpy/engine/nodes.py @@ -360,6 +360,13 @@ def equals(self, otherDateTime): return None if normalized_thisdt_list[i] != normalized_otherdt_list[i]: return False + tz_thisdt_list = len(thisdt_list) >= 8 and thisdt_list[7] is not None + tz_otherdt_list = len(otherdt_list) >= 8 and otherdt_list[7] is not None + if (tz_thisdt_list and not tz_otherdt_list) or ( + tz_otherdt_list and not tz_thisdt_list + ): + return False + return None def _normalize_datetime(self, dt_list):