Skip to content

Commit

Permalink
fix: relay api type error
Browse files Browse the repository at this point in the history
  • Loading branch information
alextes committed Dec 23, 2022
1 parent 7a9ce22 commit 1b5feb6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/relay/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export const fetchPayloads = (): Promise<Array<ApiPayload>> =>

export const fetchPayloadStats = (): Promise<ApiPayloadStats> =>
fetch(`${getApiUrl()}/api/payloads/count`)
.then((res) => res.json())
.then((res) => res.json() as Promise<ApiPayloadStats>)
.then(
({ count, totalValue, firstPayloadAt }) =>
({
Expand All @@ -62,7 +62,7 @@ export const fetchValidators = (): Promise<Array<ApiValidator>> =>

export const fetchValidatorStats = (): Promise<ApiValidatorStats> =>
fetch(`${getApiUrl()}/api/validators/count`)
.then((res) => res.json())
.then((res) => res.json() as Promise<ApiValidatorStats>)
.then(
({ validatorCount, knownValidatorCount, recipientCount }) =>
({
Expand Down

0 comments on commit 1b5feb6

Please sign in to comment.