aboutsummaryrefslogtreecommitdiff
path: root/packages/merchant-backoffice-ui/src/components
diff options
context:
space:
mode:
authorSebastian <sebasjm@gmail.com>2024-01-18 16:16:21 -0300
committerSebastian <sebasjm@gmail.com>2024-01-18 16:16:34 -0300
commit421b5c0acfa310fcb7f1893bf81e38f2876e1cbf (patch)
tree4511c7833fd79bc1aea3ab9471d489033fc4293d /packages/merchant-backoffice-ui/src/components
parentcb860500b5269e6fb18345e8646d906039d36496 (diff)
downloadwallet-core-421b5c0acfa310fcb7f1893bf81e38f2876e1cbf.tar.xz
fix templates
Diffstat (limited to 'packages/merchant-backoffice-ui/src/components')
-rw-r--r--packages/merchant-backoffice-ui/src/components/form/InputDuration.tsx3
1 files changed, 3 insertions, 0 deletions
diff --git a/packages/merchant-backoffice-ui/src/components/form/InputDuration.tsx b/packages/merchant-backoffice-ui/src/components/form/InputDuration.tsx
index 7aa2703a4..c9226ad69 100644
--- a/packages/merchant-backoffice-ui/src/components/form/InputDuration.tsx
+++ b/packages/merchant-backoffice-ui/src/components/form/InputDuration.tsx
@@ -58,6 +58,9 @@ export function InputDuration<T>({
} else if (value.d_ms === "forever") {
strValue = i18n.str`forever`;
} else {
+ if (value.d_ms === undefined) {
+ throw Error(`assertion error: duration should have a d_ms but got '${JSON.stringify(value)}'`)
+ }
strValue = formatDuration(
intervalToDuration({ start: 0, end: value.d_ms }),
{