Commit 8cba886
Allow $0 as valid card limit when editing Expensify Card
The validation in DynamicExpensifyCardLimitPage used !Number(values.limit)
to check for invalid amounts. Since Number('0') is 0 and !0 is true,
a $0 limit was always rejected as invalid. This prevented editing cards
whose limit was set to $0 in Expensify Classic.
Changed the check to Number.isNaN(Number(values.limit)) which correctly
allows 0 while still rejecting non-numeric input.
Co-authored-by: Georgia Monahan <grgia@users.noreply.github.com>1 parent c5403b4 commit 8cba886
1 file changed
Lines changed: 1 addition & 1 deletion
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
| 108 | + | |
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
| |||
0 commit comments