Skip to content

Commit

Permalink
Minor changes on informations about transfers
Browse files Browse the repository at this point in the history
  • Loading branch information
vncoelho committed Oct 20, 2023
1 parent cba2ac9 commit f301341
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions assets/eco-scripts/wallet_center.js
Original file line number Diff line number Diff line change
Expand Up @@ -684,10 +684,11 @@ function createNep17Tx() {
if (!checkIfWalletIsConnected())
return false;

var amountToTransfer = $("#transfer_nep17_amount")[0].value;
var rawAmountToTransfer = $("#transfer_nep17_amount")[0].value;

var amountToTransferAdjusted = rawAmountToTransfer;
if ($("#nep17_asset")[0].value == "GAS")
amountToTransfer = getFixed8Integer(amountToTransfer);
amountToTransferAdjusted = getFixed8Integer(rawAmountToTransfer);

if ($("#transfer_nep17_amount")[0].value == 0) {
swal("Transfer amount is currently 0", {
Expand All @@ -700,7 +701,7 @@ function createNep17Tx() {

swal({
title: "Transfer from " + ECO_WALLET[CONNECTED_WALLET_ID].label,
text: amountToTransfer + " " + $("#labelForTransferAsset")[0].textContent + " " + $("#labelForTransferTo")[0].textContent,
text: rawAmountToTransfer + " " + $("#labelForTransferAsset")[0].textContent + " " + $("#labelForTransferTo")[0].textContent,
icon: "info",
buttons: ["Cancel", "Proceed",],
}).then((willTransfer) => {
Expand All @@ -718,7 +719,7 @@ function createNep17Tx() {
},
{
type: "Integer",
value: amountToTransfer
value: amountToTransferAdjusted
},
{
type: "Integer",
Expand Down

0 comments on commit f301341

Please sign in to comment.