MSFTserver / TipBot

Crypto coin TipBot for discord
MIT License
40 stars 117 forks source link

withdrawl no tx id #29

Closed AstaClover closed 3 years ago

AstaClover commented 5 years ago

when i withdraw no tx id appear, but the coin sent, please tell how to enable the tx id function

CryptoLover705 commented 5 years ago

The txid area is located in the coinTipper.js file

this is line 124 to 171

 ticker.getBalance(tipper, 1, function(err, balance) {
    if (err) {
      message.reply('Error getting CoinName (ticker) balance.').then(message => message.delete(10000));
    } else {
      if (Number(amount) + Number(paytxfee) > Number(balance)) {
        message.channel.send('Please leave atleast ' + paytxfee + ' Coinname (ticker) for transaction fees!');
        return;
      }
      ticker.sendFrom(tipper, address, Number(amount), function(err, txId) {
        if (err) {
          message.reply(err.message).then(message => message.delete(10000));
        } else {
        message.channel.send({embed:{
        description: '**:outbox_tray::money_with_wings::moneybag: CoinName (ticker) Transaction Completed!:moneybag::money_with_wings::outbox_tray:**',
        color: 1363892,
        fields: [
          {
            name: '__Sender__',
            value: '<@' + message.author.id + '>',
            inline: true
          },
          {
            name: '__Receiver__',
            value: '**' + address + '**\n' + addyLink(address),
            inline: true
          },
          {
            name: '__txid__',
            value: '**' + txId + '**\n' + txLink(txId),
            inline: false
          },
          {
            name: '__Amount__',
            value: '**' + amount.toString() + '**',
            inline: true
          },
          {
            name: '__Fee__',
            value: '**' + paytxfee.toString() + '**',
            inline: true
          }
        ]
      }});
      }
    });
    }
  });
}
MSFTserver commented 3 years ago

It should already be enabled per the code above shows, closing this for now, if it is still an issue i can reopen this