fix: validate number on the reducer
This commit is contained in:
parent
a1e8e8bc4c
commit
d8a89e6aa2
2 changed files with 11 additions and 8 deletions
|
|
@ -4,4 +4,4 @@ const isValidNumber = R.both(R.is(Number), R.complement(R.equals(NaN)))
|
|||
|
||||
const transformNumber = value => (isValidNumber(value) ? value : null)
|
||||
|
||||
export { transformNumber, isValidNumber }
|
||||
export { transformNumber }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue