bugfix: input value handles undefined/null

This commit is contained in:
Michael Shanks 2020-06-02 14:48:18 +01:00
parent f9217bbecd
commit d09085fdf3
1 changed files with 1 additions and 1 deletions

View File

@ -17,7 +17,7 @@
onChange(value) onChange(value)
} }
$: displayValue = suffix && value.endsWith(suffix) ? value.replace(new RegExp(`${suffix}$`), "") : value $: displayValue = suffix && value && value.endsWith(suffix) ? value.replace(new RegExp(`${suffix}$`), "") : (value || "")
</script> </script>