@aurigami/sdk 1.9.3 → 1.9.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/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.9.3",
2
+ "version": "1.9.4",
3
3
  "license": "MIT",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",
@@ -70,4 +70,4 @@
70
70
  "jest": {
71
71
  "testURL": "https://app.aurigami.finance"
72
72
  }
73
- }
73
+ }
package/src/SDK.ts CHANGED
@@ -86,9 +86,10 @@ export class SdkRead extends BlockchainEntityRead {
86
86
 
87
87
  public async sneakAccounts(
88
88
  accounts: string[],
89
- tokenAddresses: string[]
89
+ tokenAddresses: string[],
90
+ dust: BigNumber = new BigNumber(0.1)
90
91
  ): Promise<types.AccountAuTokensInfo[]> {
91
- return this._misc.sneakAccounts(accounts, tokenAddresses);
92
+ return this._misc.sneakAccounts(accounts, tokenAddresses, dust);
92
93
  }
93
94
  }
94
95
 
@@ -279,10 +279,10 @@ export class MiscRead extends BlockchainEntityRead {
279
279
 
280
280
  public async sneakAccounts(
281
281
  accounts: string[],
282
- tokenAddresses: string[]
282
+ tokenAddresses: string[],
283
+ dust: BigNumber = new BigNumber(0.1)
283
284
  ): Promise<types.AccountAuTokensInfo[]> {
284
285
  const _1E18 = BN.from(10).pow(18);
285
- const dust = new BigNumber(0.1);
286
286
  const oracle = this.env.getContract<PriceOracle>(
287
287
  consts.networkAddresses.misc.oracle,
288
288
  abis.AuriOracleABI.abi
@@ -305,7 +305,7 @@ export class MiscRead extends BlockchainEntityRead {
305
305
  let balR = new BigNumber(bal.toString()).dividedBy(_1E18.toString());
306
306
  let borR = new BigNumber(bor.toString()).dividedBy(_1E18.toString());
307
307
 
308
- if (balR.lt(dust) && borR.lt(dust)) continue;
308
+ if (balR.lte(dust) && borR.lte(dust)) continue;
309
309
 
310
310
  infos.push({
311
311
  token: getSymbol(tokenAddresses[i]),