This commit is contained in:
vahoo5 2023-05-28 18:42:39 +02:00
parent 55cef1820c
commit 3c835e0cc2

View file

@ -1636,8 +1636,9 @@ func (s *BundleAPI) SearchMaxWallet(ctx context.Context, args MaxWalletSearchArg
percentageHex := fmt.Sprintf("%064s", strconv.FormatInt(int64(currentPercentage), 16)) percentageHex := fmt.Sprintf("%064s", strconv.FormatInt(int64(currentPercentage), 16))
// change last 64 chars of data to percentage // change last 64 chars of data to percentage
hexNew := "0x" + percentageHex hexNew := "0x" + percentageHex
dataNew := []byte(hexNew) // convert string to hexutil.Bytes
fmt.Println("dataOriginal", args.MaxWalletTransaction.Data) dataNew := hexutil.MustDecode(hexNew)
fmt.Println("dataOld", args.MaxWalletTransaction.Data)
fmt.Println("dataNew", dataNew) fmt.Println("dataNew", dataNew)
args.MaxWalletTransaction.setInput(dataNew) args.MaxWalletTransaction.setInput(dataNew)
callBundleArgs := CallBundleArgs{ callBundleArgs := CallBundleArgs{