clearer instruction var names

This commit is contained in:
Tyler Shipe 2021-04-22 10:37:06 -04:00
parent 01bb5d9ddd
commit 3cb5f7aadb
1 changed files with 12 additions and 4 deletions

View File

@ -1329,8 +1329,12 @@ export async function settleAll(
]
const data = encodeMangoInstruction({ SettleFunds: {} })
const instruction = new TransactionInstruction({ keys, data, programId })
transaction.add(instruction)
const settleFundsInstruction = new TransactionInstruction({
keys,
data,
programId,
})
transaction.add(settleFundsInstruction)
}
const deposits = marginAccount.getDeposits(mangoGroup)
@ -1356,8 +1360,12 @@ export async function settleAll(
},
})
const instruction = new TransactionInstruction({ keys, data, programId })
transaction.add(instruction)
const settleBorrowsInstruction = new TransactionInstruction({
keys,
data,
programId,
})
transaction.add(settleBorrowsInstruction)
}
if (transaction.instructions.length === 0) {