Browse Source

Remove useless assignments

xno
codesoap 1 year ago
parent
commit
378e76490b
  1. 2
      balance.go
  2. 4
      util.go

2
balance.go

@ -77,7 +77,7 @@ func receivePendingSends(info accountInfo, privateKey *big.Int) (updatedBalance @@ -77,7 +77,7 @@ func receivePendingSends(info accountInfo, privateKey *big.Int) (updatedBalance
err = fmt.Errorf("cannot parse '%s' as an integer", source.Amount)
return
}
updatedBalance = updatedBalance.Add(updatedBalance, amount)
updatedBalance.Add(updatedBalance, amount)
txt := "Creating receive block for %s from %s... "
fmt.Fprintf(os.Stderr, txt, rawToNanoString(amount), source.Source)

4
util.go

@ -80,12 +80,12 @@ func base32Decode(in string) (*big.Int, error) { @@ -80,12 +80,12 @@ func base32Decode(in string) (*big.Int, error) {
out := big.NewInt(0)
radix := big.NewInt(32)
for _, r := range in {
out = out.Mul(out, radix)
out.Mul(out, radix)
val, ok := reverseAlphabet[r]
if !ok {
return out, fmt.Errorf("'%c' is no legal base32 character", r)
}
out = out.Add(out, val)
out.Add(out, val)
}
return out, nil
}

Loading…
Cancel
Save