From 6bee6bbbdfe11238b83d23ee51e83f62304d23d4 Mon Sep 17 00:00:00 2001 From: LSvekis Date: Tue, 29 Jun 2021 21:10:00 -0400 Subject: [PATCH] Update ex4 --- Chapter 11/ex4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Chapter 11/ex4 b/Chapter 11/ex4 index 9c5e442..8b26228 100644 --- a/Chapter 11/ex4 +++ b/Chapter 11/ex4 @@ -8,7 +8,7 @@ window.setTimeout(update, 1000); } function countdown() { - const total = Date.parse(endDate) - Date.parse(new Date()); + const total = Date.parse(endDate) - new Date(); const seconds = Math.floor((total / 1000) % 60); const minutes = Math.floor((total / 1000 / 60) % 60); const hours = Math.floor((total / (1000 * 60 * 60)) % 24);