File tree Expand file tree Collapse file tree 1 file changed +1
-17
lines changed
third_party/pyth/multisig-wh-message-builder/src Expand file tree Collapse file tree 1 file changed +1
-17
lines changed Original file line number Diff line number Diff line change @@ -833,13 +833,6 @@ function hasWormholePayload(
833833 onChainInstructions : InstructionAccount [ ] ,
834834 wormholeTools : WormholeTools
835835) : boolean {
836- if ( onChainInstructions . length !== 2 ) {
837- console . debug (
838- `Expected 2 instructions in the transaction, found ${ onChainInstructions . length } `
839- ) ;
840- return false ;
841- }
842-
843836 const [ messagePDA ] = getIxAuthorityPDA (
844837 txPubkey ,
845838 new anchor . BN ( 1 ) ,
@@ -854,16 +847,7 @@ function hasWormholePayload(
854847 wormholeTools
855848 ) ;
856849
857- return (
858- isEqualOnChainInstruction (
859- wormholeIxs [ 0 ] ,
860- onChainInstructions [ 0 ] as InstructionAccount
861- ) &&
862- isEqualOnChainInstruction (
863- wormholeIxs [ 1 ] ,
864- onChainInstructions [ 1 ] as InstructionAccount
865- )
866- ) ;
850+ return areEqualOnChainInstructions ( wormholeIxs , onChainInstructions ) ;
867851}
868852
869853function isEqualOnChainInstruction (
You can’t perform that action at this time.
0 commit comments