Skip to content

Commit

Permalink
[list requests] update requests
Browse files Browse the repository at this point in the history
  • Loading branch information
mike-diamond committed Feb 19, 2024
1 parent 07794d2 commit 312e236
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions src/methods/vault/requests/getBlocklist/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,11 @@ const getBlocklist = async (input: GetBlocklistInput): Promise<GetBlocklistOutpu
}
}

const vault = vaultAddress.toLowerCase()

const where = search
? { vault: vaultAddress, address_contains: search } as BlocklistAccountsQueryVariables['where']
: { vault: vaultAddress } as BlocklistAccountsQueryVariables['where']
? { vault, address_contains: search.toLowerCase() } as BlocklistAccountsQueryVariables['where']
: { vault } as BlocklistAccountsQueryVariables['where']

return graphql.subgraph.vault.fetchBlocklistAccountsQuery<ModifiedBlocklist>({
url: apiUrls.getSubgraphqlUrl(options),
Expand Down
6 changes: 4 additions & 2 deletions src/methods/vault/requests/getWhitelist/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,11 @@ const getWhitelist = async (input: GetWhitelistInput): Promise<GetWhitelistOutpu
}
}

const vault = vaultAddress.toLowerCase()

const where = search
? { vault: vaultAddress, address_contains: search } as WhitelistAccountsQueryVariables['where']
: { vault: vaultAddress } as WhitelistAccountsQueryVariables['where']
? { vault, address_contains: search.toLowerCase() } as WhitelistAccountsQueryVariables['where']
: { vault } as WhitelistAccountsQueryVariables['where']

return graphql.subgraph.vault.fetchWhitelistAccountsQuery<ModifiedWhitelist>({
url: apiUrls.getSubgraphqlUrl(options),
Expand Down

0 comments on commit 312e236

Please sign in to comment.