@stake-dao/reader 0.4.91 → 0.4.92

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.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lockers/fetch/index.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAA;AAK5C,OAA6B,EAAE,KAAK,cAAc,EAAE,MAAM,kCAAkC,CAAA;AAsB5F,UAAU,aAAa;IACrB,QAAQ,EAAE,GAAG,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;IACf,MAAM,EAAE,KAAK,EAAE,CAAA;CAChB;AAED,eAAO,MAAM,YAAY,kCAAyC,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsS9E,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lockers/fetch/index.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAA;AAK5C,OAA6B,EAAE,KAAK,cAAc,EAAE,MAAM,kCAAkC,CAAA;AAsB5F,UAAU,aAAa;IACrB,QAAQ,EAAE,GAAG,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;IACf,MAAM,EAAE,KAAK,EAAE,CAAA;CAChB;AAED,eAAO,MAAM,YAAY,kCAAyC,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyS9E,CAAA"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@stake-dao/reader",
3
3
  "description": "",
4
- "version": "0.4.91",
4
+ "version": "0.4.92",
5
5
  "license": "AGPL-3.0-only",
6
6
  "repository": {
7
7
  "type": "git",
@@ -190,7 +190,7 @@ export const fetchLockers = async ({ provider, chainId, prices }: TFetchLockers)
190
190
  : prices.find((p) => p.address === r.address)?.usdPrice || 0
191
191
 
192
192
  const periodFinish = Number(formatUnits(rawData ? rawData[2] : Zero, 0))
193
- const streaming = r.distribution === 'streamed' && periodFinish > Math.floor(Date.now() / 1000)
193
+ let streaming = r.distribution === 'streamed' && periodFinish > Math.floor(Date.now() / 1000)
194
194
 
195
195
  const rate = rawData ? rawData[3] : Zero
196
196
  const oneYearRate = rate * BigInt(ONE_YEAR)
@@ -202,7 +202,10 @@ export const fetchLockers = async ({ provider, chainId, prices }: TFetchLockers)
202
202
  : 0
203
203
 
204
204
  if (r.distribution === 'merkl') {
205
- if (locker.id === 'ynd') apr = httpCalls.yieldnestMerkl?.apr || 0
205
+ if (locker.id === 'ynd') {
206
+ apr = httpCalls.yieldnestMerkl?.apr || 0
207
+ streaming = apr > 0
208
+ }
206
209
  }
207
210
 
208
211
  // Remove fees from APR