Wait for the new channel to be active before resuming the htlc

This commit is contained in:
Yaacov Akiba Slama
2020-08-11 17:16:04 +03:00
parent 26cd383aa9
commit 987e6a1ff5
2 changed files with 58 additions and 17 deletions

4
db.go
View File

@@ -24,7 +24,7 @@ func pgConnect() error {
return nil
}
func paymentInfo(paymentHash []byte) ([]byte, []byte, int64, int64, []byte, int32, error) {
func paymentInfo(paymentHash []byte) ([]byte, []byte, int64, int64, []byte, uint32, error) {
var (
paymentSecret, destination []byte
incomingAmountMsat, outgoingAmountMsat int64
@@ -42,7 +42,7 @@ func paymentInfo(paymentHash []byte) ([]byte, []byte, int64, int64, []byte, int3
}
return nil, nil, 0, 0, nil, 0, err
}
return paymentSecret, destination, incomingAmountMsat, outgoingAmountMsat, fundingTxID, fundingTxOutnum.Int, nil
return paymentSecret, destination, incomingAmountMsat, outgoingAmountMsat, fundingTxID, uint32(fundingTxOutnum.Int), nil
}
func setFundingTx(paymentHash, fundingTxID []byte, fundingTxOutnum int) error {