@theliem/xmarket-sdk 3.8.0 → 3.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1941,7 +1941,7 @@ ${logs.join("\n")}`);
1941
1941
  { pubkey: hookConfig, isSigner: false, isWritable: false },
1942
1942
  { pubkey: hookProgram, isSigner: false, isWritable: false }
1943
1943
  );
1944
- const matchIx = await this.program.methods.matchMintOrders(takerNonce, fillAmount).accounts({
1944
+ const matchIx = await this.program.methods.matchMintOrders(takerNonce, fillAmount, true).accounts({
1945
1945
  operator: operatorWallet.publicKey,
1946
1946
  payer: this.walletPubkey,
1947
1947
  clobConfig,
@@ -2037,17 +2037,21 @@ ${logs.join("\n")}`);
2037
2037
  if (yesSigned.order.fee.gtn(0) && this.programIds.feeManagement && this.feeConfigOwner) {
2038
2038
  const companyAddr = await this.companyAddress();
2039
2039
  if (companyAddr) {
2040
- const oracleVault = opts?.marketOracleVault ?? this.walletPubkey;
2041
- remainingAccounts.push(
2042
- { pubkey: this.programIds.feeManagement, isSigner: false, isWritable: false },
2043
- { pubkey: PDA.feeConfig(this.feeConfigOwner, this.programIds)[0], isSigner: false, isWritable: false },
2044
- { pubkey: PDA.marketFeeOverride(condition, this.programIds)[0], isSigner: false, isWritable: false },
2045
- { pubkey: getAssociatedTokenAddressSync(collateralMint, companyAddr), isSigner: false, isWritable: true },
2046
- { pubkey: oracleVault, isSigner: false, isWritable: true }
2047
- );
2040
+ const feeOverridePda = PDA.marketFeeOverride(condition, this.programIds)[0];
2041
+ const feeOverrideExists = await this.provider.connection.getAccountInfo(feeOverridePda);
2042
+ if (feeOverrideExists) {
2043
+ const oracleVault = opts?.marketOracleVault ?? this.walletPubkey;
2044
+ remainingAccounts.push(
2045
+ { pubkey: this.programIds.feeManagement, isSigner: false, isWritable: false },
2046
+ { pubkey: PDA.feeConfig(this.feeConfigOwner, this.programIds)[0], isSigner: false, isWritable: false },
2047
+ { pubkey: feeOverridePda, isSigner: false, isWritable: false },
2048
+ { pubkey: getAssociatedTokenAddressSync(collateralMint, companyAddr), isSigner: false, isWritable: true },
2049
+ { pubkey: oracleVault, isSigner: false, isWritable: true }
2050
+ );
2051
+ }
2048
2052
  }
2049
2053
  }
2050
- const matchIx = await this.program.methods.matchMergeOrders(takerNonce, fillAmount).accounts({
2054
+ const matchIx = await this.program.methods.matchMergeOrders(takerNonce, fillAmount, true).accounts({
2051
2055
  operator: operatorWallet.publicKey,
2052
2056
  payer: this.walletPubkey,
2053
2057
  clobConfig,
@@ -9100,6 +9104,10 @@ var clob_exchange_default = {
9100
9104
  {
9101
9105
  name: "fill_amount",
9102
9106
  type: "u64"
9107
+ },
9108
+ {
9109
+ name: "skip_crossing_check",
9110
+ type: "bool"
9103
9111
  }
9104
9112
  ]
9105
9113
  },
@@ -9391,6 +9399,10 @@ var clob_exchange_default = {
9391
9399
  {
9392
9400
  name: "fill_amount",
9393
9401
  type: "u64"
9402
+ },
9403
+ {
9404
+ name: "skip_crossing_check",
9405
+ type: "bool"
9394
9406
  }
9395
9407
  ]
9396
9408
  },