@aurigami/sdk 1.8.2 → 1.8.4

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/SDK.d.ts CHANGED
@@ -41,10 +41,9 @@ export declare class SdkRead extends BlockchainEntityRead {
41
41
  }
42
42
  export declare class SdkReadWrite extends SdkRead {
43
43
  /**
44
- * Claim PLY reward in all markets + staking pools
44
+ * Claim rewards in all markets + staking pools
45
45
  */
46
46
  claim(): Promise<TransactionResponse>;
47
- claimLpRewards(): Promise<TransactionResponse>;
48
47
  stake(amount: TokenAmount): Promise<TransactionResponse>;
49
48
  unstake(amount: TokenAmount): Promise<TransactionResponse>;
50
49
  }
@@ -166,6 +166,24 @@ var REFERRAL_CAMPAIGNS = /*#__PURE__*/Object.fromEntries([['referral-2505', {
166
166
  }], ['referrer-2505', {
167
167
  start: 1652882400,
168
168
  end: 1653487199
169
+ }], ['referral-0106', {
170
+ start: 1653487200,
171
+ end: 1654091999
172
+ }], ['referrer-0106', {
173
+ start: 1653487200,
174
+ end: 1654091999
175
+ }], ['referral-0806', {
176
+ start: 1654092000,
177
+ end: 1654696799
178
+ }], ['referrer-0806', {
179
+ start: 1654092000,
180
+ end: 1654696799
181
+ }], ['referral-1506', {
182
+ start: 1654696800,
183
+ end: 1655301599
184
+ }], ['referrer-1506', {
185
+ start: 1654696800,
186
+ end: 1655301599
169
187
  }]]);
170
188
 
171
189
  var decimalRecords = {
@@ -4436,7 +4454,7 @@ var MiscRead = /*#__PURE__*/function (_BlockchainEntityRead) {
4436
4454
  balR = new BigNumber(bal.toString()).dividedBy(_1E18.toString());
4437
4455
  borR = new BigNumber(bor.toString()).dividedBy(_1E18.toString());
4438
4456
 
4439
- if (!(balR.lt(dust) || borR.lt(dust))) {
4457
+ if (!(balR.lt(dust) && borR.lt(dust))) {
4440
4458
  _context5.next = 26;
4441
4459
  break;
4442
4460
  }
@@ -5189,7 +5207,7 @@ var SdkReadWrite = /*#__PURE__*/function (_SdkRead) {
5189
5207
  var _proto2 = SdkReadWrite.prototype;
5190
5208
 
5191
5209
  /**
5192
- * Claim PLY reward in all markets + staking pools
5210
+ * Claim rewards in all markets + staking pools
5193
5211
  */
5194
5212
  _proto2.claim =
5195
5213
  /*#__PURE__*/
@@ -5199,15 +5217,9 @@ var SdkReadWrite = /*#__PURE__*/function (_SdkRead) {
5199
5217
  while (1) {
5200
5218
  switch (_context10.prev = _context10.next) {
5201
5219
  case 0:
5202
- _context10.t0 = this.env.comptroller.connect(this._networkConnection.signer);
5203
- _context10.next = 3;
5204
- return this._networkConnection.signer.getAddress();
5205
-
5206
- case 3:
5207
- _context10.t1 = _context10.sent;
5208
- return _context10.abrupt("return", _context10.t0['claimReward(uint8,address)'].call(_context10.t0, 0, _context10.t1));
5220
+ return _context10.abrupt("return", this.env.auriLens.connect(this._networkConnection.signer).claimRewards(this.env.comptroller.address, this.env.auriFairLaunch.address, ALL_STAKING_POOLS));
5209
5221
 
5210
- case 5:
5222
+ case 1:
5211
5223
  case "end":
5212
5224
  return _context10.stop();
5213
5225
  }
@@ -5222,22 +5234,15 @@ var SdkReadWrite = /*#__PURE__*/function (_SdkRead) {
5222
5234
  return claim;
5223
5235
  }();
5224
5236
 
5225
- _proto2.claimLpRewards = /*#__PURE__*/function () {
5226
- var _claimLpRewards = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee11() {
5237
+ _proto2.stake = /*#__PURE__*/function () {
5238
+ var _stake = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee11(amount) {
5227
5239
  return runtime_1.wrap(function _callee11$(_context11) {
5228
5240
  while (1) {
5229
5241
  switch (_context11.prev = _context11.next) {
5230
5242
  case 0:
5231
- _context11.t0 = this.env.auriFairLaunch.connect(this._networkConnection.signer);
5232
- _context11.next = 3;
5233
- return this._networkConnection.signer.getAddress();
5243
+ return _context11.abrupt("return", new StakingReadWrite(this._networkConnection).stake(amount));
5234
5244
 
5235
- case 3:
5236
- _context11.t1 = _context11.sent;
5237
- _context11.t2 = INF;
5238
- return _context11.abrupt("return", _context11.t0.harvest.call(_context11.t0, _context11.t1, 0, _context11.t2));
5239
-
5240
- case 6:
5245
+ case 1:
5241
5246
  case "end":
5242
5247
  return _context11.stop();
5243
5248
  }
@@ -5245,29 +5250,6 @@ var SdkReadWrite = /*#__PURE__*/function (_SdkRead) {
5245
5250
  }, _callee11, this);
5246
5251
  }));
5247
5252
 
5248
- function claimLpRewards() {
5249
- return _claimLpRewards.apply(this, arguments);
5250
- }
5251
-
5252
- return claimLpRewards;
5253
- }();
5254
-
5255
- _proto2.stake = /*#__PURE__*/function () {
5256
- var _stake = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee12(amount) {
5257
- return runtime_1.wrap(function _callee12$(_context12) {
5258
- while (1) {
5259
- switch (_context12.prev = _context12.next) {
5260
- case 0:
5261
- return _context12.abrupt("return", new StakingReadWrite(this._networkConnection).stake(amount));
5262
-
5263
- case 1:
5264
- case "end":
5265
- return _context12.stop();
5266
- }
5267
- }
5268
- }, _callee12, this);
5269
- }));
5270
-
5271
5253
  function stake(_x9) {
5272
5254
  return _stake.apply(this, arguments);
5273
5255
  }
@@ -5276,19 +5258,19 @@ var SdkReadWrite = /*#__PURE__*/function (_SdkRead) {
5276
5258
  }();
5277
5259
 
5278
5260
  _proto2.unstake = /*#__PURE__*/function () {
5279
- var _unstake = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee13(amount) {
5280
- return runtime_1.wrap(function _callee13$(_context13) {
5261
+ var _unstake = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/runtime_1.mark(function _callee12(amount) {
5262
+ return runtime_1.wrap(function _callee12$(_context12) {
5281
5263
  while (1) {
5282
- switch (_context13.prev = _context13.next) {
5264
+ switch (_context12.prev = _context12.next) {
5283
5265
  case 0:
5284
- return _context13.abrupt("return", new StakingReadWrite(this._networkConnection).unstake(amount));
5266
+ return _context12.abrupt("return", new StakingReadWrite(this._networkConnection).unstake(amount));
5285
5267
 
5286
5268
  case 1:
5287
5269
  case "end":
5288
- return _context13.stop();
5270
+ return _context12.stop();
5289
5271
  }
5290
5272
  }
5291
- }, _callee13, this);
5273
+ }, _callee12, this);
5292
5274
  }));
5293
5275
 
5294
5276
  function unstake(_x10) {