Skip to content
This repository has been archived by the owner on Dec 16, 2021. It is now read-only.

fix: instant lock messages not being set properly #327

Merged
merged 1 commit into from
Dec 24, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix: instant lock messages not being set properly
  • Loading branch information
antouhou committed Dec 24, 2020
commit aa388054f21120a0b7cd66aec708930eef99daed
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ const {
v0: {
TransactionsWithProofsResponse,
RawTransactions,
InstantSendLockMessages,
},
} = require('@dashevo/dapi-grpc');

Expand Down Expand Up @@ -63,8 +64,11 @@ async function sendMerkleBlockResponse(call, merkleBlock) {
* @returns {Promise<void>}
*/
async function sendInstantLockResponse(call, instantLock) {
const instantSendLockMessages = new InstantSendLockMessages();
instantSendLockMessages.setMessagesList([instantLock.toBuffer()]);

const response = new TransactionsWithProofsResponse();
response.setInstantSendLockMessages([instantLock.toBuffer()]);
response.setInstantSendLockMessages(instantSendLockMessages);

await call.write(response);
}
Expand Down