@1delta/margin-fetcher 0.0.4 → 0.0.5

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": "@1delta/margin-fetcher",
3
- "version": "0.0.4",
3
+ "version": "0.0.5",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -111,7 +111,8 @@ export const convertLenderUserDataResult = (
111
111
  const convertedData = converter(data)
112
112
 
113
113
  if (convertedData) {
114
- lenderData[query.lender] = convertedData
114
+ // map it to the user address
115
+ lenderData[query.lender] = { [query.account.toLowerCase()]: convertedData }
115
116
  }
116
117
  } catch (e) {
117
118
  console.log("Error parsing for", query.lender, "on", chainId, e)
@@ -90,8 +90,8 @@ describe(
90
90
  try {
91
91
  const { userData } = await getUserData(Chain.POLYGON_MAINNET, [Lender.YLDR]);
92
92
 
93
- console.log("YLDR Polygon user data:", userData[Lender.YLDR].balanceData);
94
- console.log("YLDR Polygon user aprData:", userData[Lender.YLDR].aprData);
93
+ console.log("YLDR Polygon user data:", userData[Lender.YLDR]);
94
+ console.log("YLDR Polygon user aprData:", userData[Lender.YLDR]);
95
95
 
96
96
  // Basic validation
97
97
  expect(userData).toBeDefined();