1
0
Fork 0
mirror of synced 2024-10-01 17:47:46 +13:00

bugfix: input value handles undefined/null

This commit is contained in:
Michael Shanks 2020-06-02 14:48:18 +01:00
parent b7b51bd4d5
commit a11d27f867

View file

@ -17,7 +17,7 @@
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>