Skip to content

Commit

Permalink
add nan check
Browse files Browse the repository at this point in the history
  • Loading branch information
terryli0095 committed Apr 6, 2024
1 parent 795e857 commit 8bc96aa
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ const MemberAddBody = ({ onClose }) => {
}
if (points) {
const integerPoints = parseInt(points);
if (!integerPoints || integerPoints < 0) {
if (isNaN(integerPoints)|| integerPoints < 0) {
setError("Points must be a positive integer");
return;
}
Expand Down

0 comments on commit 8bc96aa

Please sign in to comment.