Skip to content

Commit

Permalink
Map indexId to IndexSubscription (superfluid-finance#1026)
Browse files Browse the repository at this point in the history
  • Loading branch information
kasparkallas authored Aug 9, 2022
1 parent b9b1fe8 commit 9e9228f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/sdk-core/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

## [Unreleased]

- Map `indexId` to `IndexSubscription` when querying from Subgraph

## [0.5.2] - 2022-07-26

### Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ export interface IndexSubscription {
units: BigNumber;
indexTotalUnits: BigNumber;
index: SubgraphId;
indexId: string;
token: Address;
tokenSymbol: string;
subscriber: Address;
Expand Down Expand Up @@ -77,6 +78,7 @@ export class IndexSubscriptionQueryHandler extends SubgraphQueryHandler<
updatedAtTimestamp: Number(x.updatedAtTimestamp),
updatedAtBlockNumber: Number(x.updatedAtBlockNumber),
index: x.index.id,
indexId: x.index.indexId,
indexValueCurrent: x.index.indexValue,
indexTotalUnits: x.index.totalUnits,
token: x.index.token.id,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ query indexSubscriptions($first: Int = 10, $orderBy: IndexSubscription_orderBy =
id
index {
id
indexId,
indexValue
totalUnits
token {
Expand Down

0 comments on commit 9e9228f

Please sign in to comment.