Skip to content

Commit

Permalink
fix: lowercase vesting addresses before querying subgraph
Browse files Browse the repository at this point in the history
  • Loading branch information
1emu committed Aug 13, 2024
1 parent b74cdd2 commit fb02ebc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/clients/VestingsSubgraph.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export class VestingsSubgraph {
}
`

const variables = { address }
const variables = { address: address.toLowerCase() }
const response = await fetch(this.queryEndpoint, {
method: 'post',
headers: { 'Content-Type': 'application/json' },
Expand Down Expand Up @@ -129,7 +129,9 @@ export class VestingsSubgraph {
}
}
`
const variables = queryAddresses ? { addresses } : { blockNumber: OLDEST_INDEXED_BLOCK }
const variables = queryAddresses
? { addresses: addresses.map((address) => address.toLowerCase()) }
: { blockNumber: OLDEST_INDEXED_BLOCK }
const response = await fetch(this.queryEndpoint, {
method: 'post',
headers: { 'Content-Type': 'application/json' },
Expand Down

0 comments on commit fb02ebc

Please sign in to comment.