wowok 1.5.44 → 1.5.45

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wowok",
3
- "version": "1.5.44",
3
+ "version": "1.5.45",
4
4
  "description": "Create, collaborate, and transact on your own terms with the AI-driven web3 collaboration protocol.",
5
5
  "main": "./src/index.ts",
6
6
  "types": "./src/index.ts",
@@ -1,7 +1,8 @@
1
1
  import { IsValidArray, array_unique, IsValidTokenType, IsValidDesription, parseObjectType,
2
2
  IsValidAddress, IsValidEndpoint, IsValidU64, IsValidName, } from './utils'
3
3
  import { FnCallType, GuardObject, PassportObject, PermissionObject, CoinObject, Protocol,
4
- TxbObject, ArbitrationAddress, OrderObject, ArbObject, PaymentAddress, TreasuryObject} from './protocol';
4
+ TxbObject, ArbitrationAddress, OrderObject, ArbObject, PaymentAddress, TreasuryObject,
5
+ ArbAddress} from './protocol';
5
6
  import { ERROR, Errors } from './exception';
6
7
  import { Transaction as TransactionBlock, } from '@mysten/sui/transactions';
7
8
 
@@ -438,7 +439,7 @@ export class Arbitration {
438
439
  }
439
440
  }
440
441
 
441
- dispute(param:Dispute, passport?:PassportObject) {
442
+ dispute(param:Dispute, passport?:PassportObject) : ArbAddress {
442
443
  if (!Protocol.IsValidObjects([param.order])) {
443
444
  ERROR(Errors.IsValidObjects, 'dispute.param.order')
444
445
  }
@@ -454,14 +455,14 @@ export class Arbitration {
454
455
 
455
456
  if (passport) {
456
457
  if (param.fee) {
457
- this.txb.moveCall({
458
+ return this.txb.moveCall({
458
459
  target:Protocol.Instance().ArbitrationFn('dispute_with_passport') as FnCallType,
459
460
  arguments:[passport, Protocol.TXB_OBJECT(this.txb, this.object), this.txb.object(param.order), this.txb.pure.string(param.description),
460
461
  this.txb.pure.vector('string', array_unique(param.votable_proposition)), this.txb.object(param.fee)],
461
462
  typeArguments:[this.pay_token_type, param.order_token_type]
462
463
  })
463
464
  } else {
464
- this.txb.moveCall({
465
+ return this.txb.moveCall({
465
466
  target:Protocol.Instance().ArbitrationFn('free_dispute_with_passport') as FnCallType,
466
467
  arguments:[passport, Protocol.TXB_OBJECT(this.txb, this.object), this.txb.object(param.order), this.txb.pure.string(param.description),
467
468
  this.txb.pure.vector('string', array_unique(param.votable_proposition))],
@@ -470,14 +471,14 @@ export class Arbitration {
470
471
  }
471
472
  } else {
472
473
  if (param.fee) {
473
- this.txb.moveCall({
474
+ return this.txb.moveCall({
474
475
  target:Protocol.Instance().ArbitrationFn('dispute') as FnCallType,
475
476
  arguments:[Protocol.TXB_OBJECT(this.txb, this.object), this.txb.object(param.order), this.txb.pure.string(param.description),
476
477
  this.txb.pure.vector('string', array_unique(param.votable_proposition)), this.txb.object(param.fee)],
477
478
  typeArguments:[this.pay_token_type, param.order_token_type]
478
479
  })
479
480
  } else {
480
- this.txb.moveCall({
481
+ return this.txb.moveCall({
481
482
  target:Protocol.Instance().ArbitrationFn('free_dispute') as FnCallType,
482
483
  arguments:[Protocol.TXB_OBJECT(this.txb, this.object), this.txb.object(param.order), this.txb.pure.string(param.description),
483
484
  this.txb.pure.vector('string', array_unique(param.votable_proposition))],