fix send tx
This commit is contained in:
parent
d5e89c757d
commit
f9a0c861fb
@ -126,6 +126,7 @@ func (nc *NockchainClient) WalletSendTransaction(tx *nockchain.RawTx) (*nockchai
|
||||
req := nockchain.WalletSendTransactionRequest{
|
||||
TxId: ParseHash(tx.TxId),
|
||||
RawTx: &nockchain.RawTransaction{
|
||||
Id: ParseHash(tx.TxId),
|
||||
NamedInputs: inputs,
|
||||
TotalFees: &nockchain.Nicks{Value: tx.TotalFees},
|
||||
TimelockRange: &nockchain.TimeLockRangeAbsolute{
|
||||
|
@ -455,7 +455,10 @@ func (h *GprcHandler) CreateTx(ctx context.Context, req *nockchain.CreateTxReque
|
||||
|
||||
var timelockRange *nockchain.TimelockRange
|
||||
if req.TimelockIntent == nil {
|
||||
timelockRange = nil
|
||||
timelockRange = &nockchain.TimelockRange{
|
||||
Min: nil,
|
||||
Max: nil,
|
||||
}
|
||||
} else {
|
||||
if req.TimelockIntent.Absolute != nil {
|
||||
timelockRange = req.TimelockIntent.Absolute
|
||||
|
@ -120,13 +120,17 @@ func ConvertInput(input *nockchain.NockchainInput) (*nockchain.NamedInput, error
|
||||
}
|
||||
pks = append(seedPks, pk)
|
||||
}
|
||||
seeds = append(seeds, &nockchain.Seed{
|
||||
OutputSource: &nockchain.OutputSource{
|
||||
var source *nockchain.OutputSource
|
||||
if seed.OutputSource != nil {
|
||||
source = &nockchain.OutputSource{
|
||||
Source: &nockchain.Source{
|
||||
Hash: ParseHash(seed.OutputSource.Source),
|
||||
Coinbase: input.Note.Source.IsCoinbase,
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
seeds = append(seeds, &nockchain.Seed{
|
||||
OutputSource: source,
|
||||
Recipient: &nockchain.Lock{
|
||||
KeysRequired: uint32(seed.Recipient.KeysRequired),
|
||||
SchnorrPubkeys: seedPks,
|
||||
|
Loading…
x
Reference in New Issue
Block a user