@triadxyz/triad-protocol 3.0.1-beta → 3.0.2-beta

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.d.ts CHANGED
@@ -415,7 +415,7 @@ export default class TriadProtocolClient {
415
415
  *
416
416
  * @param options - RPC options
417
417
  */
418
- cancelBidOrder({ marketId, orderId, userNonce, mint, direction, isTrdPayout, remainingShares, price }: CancelBidOrderArgs, options?: RpcOptions): Promise<string>;
418
+ cancelBidOrder({ marketId, orderId, userNonce, mint, direction }: CancelBidOrderArgs, options?: RpcOptions): Promise<string>;
419
419
  /**
420
420
  * Cancel Ask Order
421
421
  * @param args.marketId - The ID of the Market
package/dist/index.js CHANGED
@@ -826,7 +826,7 @@ class TriadProtocolClient {
826
826
  *
827
827
  * @param options - RPC options
828
828
  */
829
- cancelBidOrder({ marketId, orderId, userNonce, mint, direction, isTrdPayout, remainingShares, price }, options) {
829
+ cancelBidOrder({ marketId, orderId, userNonce, mint, direction }, options) {
830
830
  return __awaiter(this, void 0, void 0, function* () {
831
831
  const ixs = [];
832
832
  const addressLookupTableAccounts = [];
@@ -844,21 +844,6 @@ class TriadProtocolClient {
844
844
  tokenProgram: (0, helpers_1.getTokenProgram)(mint)
845
845
  })
846
846
  .instruction());
847
- if (isTrdPayout) {
848
- const { swapIxs, addressLookupTableAccounts: swapAddressLookupTableAccounts, setupInstructions } = yield (0, swap_1.swap)({
849
- connection: this.program.provider.connection,
850
- wallet: this.program.provider.publicKey.toBase58(),
851
- inToken: constants_1.USDC_MINT.toString(),
852
- outToken: constants_1.TRD_MINT.toString(),
853
- amount: Math.floor((remainingShares * price) / Math.pow(10, this.decimals))
854
- });
855
- if (swapIxs.length === 0) {
856
- return;
857
- }
858
- ixs.push(...setupInstructions);
859
- ixs.push(...swapIxs);
860
- addressLookupTableAccounts.push(...swapAddressLookupTableAccounts);
861
- }
862
847
  return (0, sendVersionedTransaction_1.default)(this.program, ixs, options);
863
848
  });
864
849
  }
@@ -196,9 +196,6 @@ export type CancelBidOrderArgs = {
196
196
  } | {
197
197
  flop: {};
198
198
  };
199
- isTrdPayout: boolean;
200
- remainingShares: number;
201
- price: number;
202
199
  };
203
200
  export type CancelAskOrderArgs = {
204
201
  marketId: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@triadxyz/triad-protocol",
3
- "version": "3.0.1-beta",
3
+ "version": "3.0.2-beta",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",