Skip to content
This repository was archived by the owner on May 28, 2023. It is now read-only.

Commit 64c8f0d

Browse files
authored
Fix for special_price active check
This is a backport for a vuestorefront/vue-storefront#2838 fix from develop branch
1 parent 4c7f7b7 commit 64c8f0d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/lib/taxcalc.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
function isSpecialPriceActive(fromDate, toDate) {
22
const now = new Date()
3-
fromDate = new Date(fromDate) || false
4-
toDate = new Date(toDate) || false
3+
fromDate = fromDate ? new Date(fromDate) : false
4+
toDate = toDate ? new Date(toDate) : false
55

66
if (!fromDate && !toDate) {
77
return true

0 commit comments

Comments
 (0)