Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.then((_signatureFragments) => {
bundle.set(addSignatureOrMessage(bundle, _signatureFragments, 1));
for (let offset = 0; offset < bundle.length; offset += Transaction.TRANSACTION_LENGTH) {
cached.trytes.push(tritsToTrytes(bundle.subarray(offset, offset + Transaction.TRANSACTION_LENGTH)));
}
const convertToTransactionObjects = (tryteString) => iota.utils.transactionObject(tryteString);
cached.transactionObjects = map(cached.trytes, convertToTransactionObjects);
// Check if prepared bundle is valid, especially if its signed correctly.
if (isBundle(cached.transactionObjects)) {
return getTransactionsToApproveAsync(settings)();
}
throw new Error(Errors.INVALID_BUNDLE);
})
.then(({ trunkTransaction, branchTransaction }) => {
.then((_signatureFragments) => {
bundle.set(addSignatureOrMessage(bundle, _signatureFragments, 1));
for (let offset = 0; offset < bundle.length; offset += Transaction.TRANSACTION_LENGTH) {
cached.trytes.push(tritsToTrytes(bundle.subarray(offset, offset + Transaction.TRANSACTION_LENGTH)));
}
const convertToTransactionObjects = (tryteString) => iota.utils.transactionObject(tryteString);
cached.transactionObjects = map(cached.trytes, convertToTransactionObjects);
// Check if prepared bundle is valid, especially if its signed correctly.
if (isBundle(cached.transactionObjects)) {
return getTransactionsToApproveAsync(settings)();
}
throw new Error(Errors.INVALID_BUNDLE);
})
.then(({ trunkTransaction, branchTransaction }) => {