From e8f27cabb3f085ea91dfd0ee5387b0a39a5bae41 Mon Sep 17 00:00:00 2001 From: raphaelreynaud-web Date: Mon, 18 Dec 2023 00:06:00 +0100 Subject: [PATCH 1/3] Issue number 1075 patched in moment-timezone.js --- moment-timezone.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/moment-timezone.js b/moment-timezone.js index dd2f0213..6e568cd2 100644 --- a/moment-timezone.js +++ b/moment-timezone.js @@ -640,7 +640,7 @@ offset; if (mom._z === undefined) { - if (zone && needsOffset(mom) && !mom._isUTC) { + if (zone && needsOffset(mom) && !mom._isUTC && mom.isValid()) { mom._d = moment.utc(mom._a)._d; mom.utc().add(zone.parse(mom), 'minutes'); } From 48dd1743172917f19a477cd260b69e4782a17a6b Mon Sep 17 00:00:00 2001 From: raphaelreynaud-web Date: Mon, 18 Dec 2023 00:09:05 +0100 Subject: [PATCH 2/3] remove patch to create new branch --- moment-timezone.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/moment-timezone.js b/moment-timezone.js index 6e568cd2..dd2f0213 100644 --- a/moment-timezone.js +++ b/moment-timezone.js @@ -640,7 +640,7 @@ offset; if (mom._z === undefined) { - if (zone && needsOffset(mom) && !mom._isUTC && mom.isValid()) { + if (zone && needsOffset(mom) && !mom._isUTC) { mom._d = moment.utc(mom._a)._d; mom.utc().add(zone.parse(mom), 'minutes'); } From b21629d75e1dc9ca1f29ad0184d64f9e9625c853 Mon Sep 17 00:00:00 2001 From: raphaelreynaud-web Date: Mon, 18 Dec 2023 00:09:37 +0100 Subject: [PATCH 3/3] patch issue 1075 --- moment-timezone.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/moment-timezone.js b/moment-timezone.js index dd2f0213..6e568cd2 100644 --- a/moment-timezone.js +++ b/moment-timezone.js @@ -640,7 +640,7 @@ offset; if (mom._z === undefined) { - if (zone && needsOffset(mom) && !mom._isUTC) { + if (zone && needsOffset(mom) && !mom._isUTC && mom.isValid()) { mom._d = moment.utc(mom._a)._d; mom.utc().add(zone.parse(mom), 'minutes'); }