Skip to content

Commit

Permalink
fix: provide default value to convert (#104)
Browse files Browse the repository at this point in the history
  • Loading branch information
meeh0w authored Dec 6, 2024
1 parent 2970d52 commit d6c3398
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/common/BNInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export function BNInput({

if (value) {
const valueAsString = bigIntToString(value, denomination);
const oldValue = stringToBigint(valStr, denomination);
const oldValue = stringToBigint(valStr || '0', denomination);
/**
* When deleting zeros after decimal, all zeros delete without this check.
* This also preserves zeros in the input ui.
Expand Down

0 comments on commit d6c3398

Please sign in to comment.