Fix jupitor
This commit is contained in:
@@ -1396,6 +1396,13 @@ func parseJupiterV6Instruction(tx VersionedTransaction, instructionIndex int) (T
|
||||
return nil, nil
|
||||
}
|
||||
if bytes.Equal(disc, jupiterRoute) {
|
||||
pumpMint, ok, err := findPumpFunMint(tx, instruction.Accounts)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if !ok {
|
||||
return nil, nil
|
||||
}
|
||||
if len(instruction.Accounts) < 13 {
|
||||
return nil, nil
|
||||
}
|
||||
@@ -1411,10 +1418,6 @@ func parseJupiterV6Instruction(tx VersionedTransaction, instructionIndex int) (T
|
||||
if !pumpKey.Equals(pumpProgramID) {
|
||||
return nil, nil
|
||||
}
|
||||
token0Mint, err := tx.GetAccount(int(instruction.Accounts[12]))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
token0Amount := decimal.Zero
|
||||
if routeIn > 0 {
|
||||
token0Amount = formatTokenAmount(routeIn)
|
||||
@@ -1422,7 +1425,7 @@ func parseJupiterV6Instruction(tx VersionedTransaction, instructionIndex int) (T
|
||||
return TxSignalBatch{&TxSignal{
|
||||
TxHash: tx.Signatures[0].String(),
|
||||
Maker: tx.StaticAccountKeys[0].String(),
|
||||
Token0Address: token0Mint.String(),
|
||||
Token0Address: pumpMint.String(),
|
||||
Token1Address: destMint.String(),
|
||||
Token0Amount: token0Amount,
|
||||
Token1Amount: decimal.Zero,
|
||||
|
||||
Reference in New Issue
Block a user