From ff9cb91f73a74e1f2890d3835e60e90943dd637c Mon Sep 17 00:00:00 2001 From: Madeorsk Date: Sat, 5 Oct 2024 16:03:58 +0200 Subject: [PATCH] Fix date property change detection. --- README.md | 2 +- package.json | 2 +- src/Model/Types/DateType.ts | 5 +++++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 24c4cf8..f9dc607 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@

- Version 3.2.0 + Version 3.2.1

## Introduction diff --git a/package.json b/package.json index a59d876..ba55fcf 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@sharkitek/core", - "version": "3.2.0", + "version": "3.2.1", "description": "TypeScript library for well-designed model architectures.", "keywords": [ "deserialization", diff --git a/src/Model/Types/DateType.ts b/src/Model/Types/DateType.ts index f8cf1a7..b075c3c 100644 --- a/src/Model/Types/DateType.ts +++ b/src/Model/Types/DateType.ts @@ -21,6 +21,11 @@ export class DateType extends Type return value?.toISOString(); } + + propertyHasChanged(originalValue: Date|null|undefined, currentValue: Date|null|undefined): boolean + { + return originalValue?.toISOString() != currentValue?.toISOString(); + } } /**