Skip to content

Commit

Permalink
solana: update arg name in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
johnsaigle committed Apr 2, 2024
1 parent e87c404 commit b8ce756
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions solana/ts/sdk/ntt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,7 @@ export class NTT {
payer: PublicKey
chain: ChainName | ChainId
nttMessage: NttMessage
revertOnDelay: boolean
revertWhenNotReady: boolean
recipient?: PublicKey
config?: Config
}): Promise<TransactionInstruction> {
Expand All @@ -449,7 +449,7 @@ export class NTT {

return await this.program.methods
.releaseInboundMint({
revertOnDelay: args.revertOnDelay
revertWhenNotReady: args.revertWhenNotReady
})
.accounts({
common: {
Expand All @@ -468,7 +468,7 @@ export class NTT {
payer: Keypair
chain: ChainName | ChainId
nttMessage: NttMessage
revertOnDelay: boolean
revertWhenNotReady: boolean
config?: Config
}): Promise<void> {
if (await this.isPaused()) {
Expand All @@ -491,7 +491,7 @@ export class NTT {
payer: PublicKey
chain: ChainName | ChainId
nttMessage: NttMessage
revertOnDelay: boolean
revertWhenNotReady: boolean
recipient?: PublicKey
config?: Config
}): Promise<TransactionInstruction> {
Expand All @@ -508,7 +508,7 @@ export class NTT {

return await this.program.methods
.releaseInboundUnlock({
revertOnDelay: args.revertOnDelay
revertWhenNotReady: args.revertWhenNotReady
})
.accounts({
common: {
Expand All @@ -528,7 +528,7 @@ export class NTT {
payer: Keypair
chain: ChainName | ChainId
nttMessage: NttMessage
revertOnDelay: boolean
revertWhenNotReady: boolean
config?: Config
}): Promise<void> {
if (await this.isPaused()) {
Expand Down Expand Up @@ -664,7 +664,7 @@ export class NTT {

return await this.program.methods.receiveWormholeMessage().accounts({
payer: args.payer,
config: { config: this.configAccountAddress() },
config: { config: this.configAccountAddress() },
peer: transceiverPeer,
vaa: derivePostedVaaKey(this.wormholeId, Buffer.from(wormholeNTT.hash)),
transceiverMessage: this.transceiverMessageAccountAddress(
Expand Down Expand Up @@ -747,7 +747,7 @@ export class NTT {
// In case the redeemed amount exceeds the remaining inbound rate limit capacity,
// the transaction gets delayed. If this happens, the second instruction will not actually
// be able to release the transfer yet.
// To make sure the transaction still succeeds, we set revertOnDelay to false, which will
// To make sure the transaction still succeeds, we set revertWhenNotReady to false, which will
// just make the second instruction a no-op in case the transfer is delayed.

const tx = new Transaction()
Expand All @@ -760,8 +760,7 @@ export class NTT {
nttMessage,
recipient: new PublicKey(nttMessage.payload.recipientAddress.toUint8Array()),
chain: chainId,
revertOnDelay: false,
config: config
revertWhenNotReady: false
}

if (config.mode.locking != null) {
Expand Down

0 comments on commit b8ce756

Please sign in to comment.