Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 4d920d6

Browse files
committed
fix: show "TBD" is no date range
ref issue #53
1 parent 5d8fa56 commit 4d920d6

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/utils/format.js

+4
Original file line numberDiff line numberDiff line change
@@ -161,5 +161,9 @@ export const formatDateRange = (startDate, endDate) => {
161161
const startDateStr = startDate ? moment(startDate).format(DAY_FORMAT) : "";
162162
const endDateStr = endDate ? moment(endDate).format(DAY_FORMAT) : "";
163163

164+
if (!startDateStr && !endDateStr) {
165+
return "TBD";
166+
}
167+
164168
return `${startDateStr} - ${endDateStr}`;
165169
};

0 commit comments

Comments
 (0)