@triadxyz/triad-protocol 3.0.8-beta → 3.0.9-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
@@ -305,6 +305,7 @@ export default class TriadProtocolClient {
305
305
  mint: PublicKey;
306
306
  shares: number;
307
307
  isTrdPayout: boolean;
308
+ isWinner: boolean;
308
309
  }[], options?: RpcOptions): Promise<string>;
309
310
  /**
310
311
  * Allow Market to Payout
package/dist/index.js CHANGED
@@ -496,8 +496,8 @@ class TriadProtocolClient {
496
496
  payoutOrder(orders, options) {
497
497
  return __awaiter(this, void 0, void 0, function* () {
498
498
  const ixs = [];
499
- if (orders.length > 10) {
500
- throw new Error('Max 10 orders per transaction');
499
+ if (orders.length > 6) {
500
+ throw new Error('Max 6 orders per transaction');
501
501
  }
502
502
  for (const order of orders) {
503
503
  ixs.push(yield this.program.methods
@@ -510,7 +510,7 @@ class TriadProtocolClient {
510
510
  tokenProgram: (0, helpers_1.getTokenProgram)(order.mint)
511
511
  })
512
512
  .instruction());
513
- if (order.isTrdPayout) {
513
+ if (order.isTrdPayout && order.isWinner) {
514
514
  const { setupInstructions, swapIxs, addressLookupTableAccounts } = yield (0, swap_1.swap)({
515
515
  connection: this.program.provider.connection,
516
516
  wallet: this.program.provider.publicKey.toBase58(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@triadxyz/triad-protocol",
3
- "version": "3.0.8-beta",
3
+ "version": "3.0.9-beta",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",