From 26844a1eabca7aa7a349790363931298e29cda6e Mon Sep 17 00:00:00 2001 From: Ahmed Awan Date: Mon, 15 Apr 2024 19:15:21 -0500 Subject: [PATCH] fix jest fail caused by `FormSelection.props.options == null` --- client/src/components/Form/Elements/FormSelection.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/client/src/components/Form/Elements/FormSelection.vue b/client/src/components/Form/Elements/FormSelection.vue index 2b533461c338..15176a48f063 100644 --- a/client/src/components/Form/Elements/FormSelection.vue +++ b/client/src/components/Form/Elements/FormSelection.vue @@ -82,7 +82,10 @@ watch( } if (newValue === "none") { - if ((Array.isArray(props.value) && props.value.length >= 15) || props.options.length >= 500) { + if ( + (Array.isArray(props.value) && props.value.length >= 15) || + (props.options && props.options.length >= 500) + ) { useMany.value = true; } else { useMany.value = false;