@aurigami/sdk 1.8.2 → 1.8.3

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,5 +1,5 @@
1
1
  {
2
- "version": "1.8.2",
2
+ "version": "1.8.3",
3
3
  "license": "MIT",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",
package/src/SDK.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { TransactionResponse } from '@ethersproject/abstract-provider';
2
2
  import BigNumber from 'bignumber.js';
3
- import * as consts from './consts';
3
+ import { ALL_STAKING_POOLS } from './consts';
4
4
  import { MiscRead, StakingRead, StakingReadWrite } from './contracts';
5
5
  import { AuriEnv, BlockchainEntity, BlockchainEntityRead, Token, TokenAmount } from './entities';
6
6
  import * as types from './types';
@@ -94,18 +94,16 @@ export class SdkRead extends BlockchainEntityRead {
94
94
 
95
95
  export class SdkReadWrite extends SdkRead {
96
96
  /**
97
- * Claim PLY reward in all markets + staking pools
97
+ * Claim rewards in all markets + staking pools
98
98
  */
99
99
  public async claim(): Promise<TransactionResponse> {
100
- return this.env.comptroller
100
+ return this.env.auriLens
101
101
  .connect(this._networkConnection.signer!)
102
- ['claimReward(uint8,address)'](0, await this._networkConnection.signer!.getAddress());
103
- }
104
-
105
- public async claimLpRewards(): Promise<TransactionResponse> {
106
- return this.env.auriFairLaunch
107
- .connect(this._networkConnection.signer!)
108
- .harvest(await this._networkConnection.signer!.getAddress(), 0, consts.INF);
102
+ .claimRewards(
103
+ this.env.comptroller.address,
104
+ this.env.auriFairLaunch.address,
105
+ ALL_STAKING_POOLS
106
+ );
109
107
  }
110
108
 
111
109
  public async stake(amount: TokenAmount): Promise<TransactionResponse> {