fix sats amount display in LND channel open dialog

This commit is contained in:
openoms 2022-04-27 07:14:45 +01:00
parent 66cf002640
commit 8101d467bd
No known key found for this signature in database
GPG Key ID: 5BFB77609B081B65

View File

@ -33,9 +33,9 @@ if [ ${chainOutSync} -eq 1 ]; then
if [ $LNTYPE = cl ];then
echo "# FAIL PRECHECK - 'lightning-cli getinfo' blockheight is different from 'bitcoind getblockchaininfo' - wait until chain is sync "
elif [ $LNTYPE = lnd ];then
echo "# FAIL PRECHECK - lncli getinfo shows 'synced_to_chain': false - wait until chain is sync "
echo "# FAIL PRECHECK - lncli getinfo shows 'synced_to_chain': false - wait until chain is sync "
fi
echo
echo
echo "# PRESS ENTER to return to menu"
read key
exit 0
@ -50,7 +50,7 @@ if [ $LNTYPE = cl ];then
confirmedBalance=$((confirmedBalance+i))
done
elif [ $LNTYPE = lnd ];then
confirmedBalance=$($lncli_alias walletbalance | grep '"confirmed_balance"' | cut -d '"' -f4)
confirmedBalance=$($lncli_alias walletbalance | jq -r .confirmed_balance)
fi
if [ ${confirmedBalance} -eq 0 ]; then
@ -113,13 +113,13 @@ pubKey=$(dialog --clear \
clear
if [ ${#pubKey} -eq 0 ]; then
clear
echo
echo
echo "no channel selected - returning to menu ..."
sleep 4
exit 0
fi
# find out what is the minimum amount
# find out what is the minimum amount
# TODO find a better way - also consider dust and channel reserve
# details see here: https://github.com/btcontract/lnwallet/issues/52
minSat=20000