Skip to content

Commit

Permalink
refact: drop costly ALL orders totalCount query (#10895)
Browse files Browse the repository at this point in the history
  • Loading branch information
kewitz authored Jan 8, 2025
1 parent 34f96cd commit 1f7da35
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions components/dashboard/sections/contributions/Contributions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -129,14 +129,7 @@ const dashboardContributionsMetadataQuery = gql`
hostFeePercent
}
}
ALL: orders(
filter: $filter
expectedFundsFilter: $expectedFundsFilter
includeHostedAccounts: $includeHostedAccounts
includeChildrenAccounts: $includeChildrenAccounts
) {
totalCount
}
PENDING: orders(
filter: $filter
expectedFundsFilter: $expectedFundsFilter
Expand Down Expand Up @@ -622,7 +615,6 @@ const Contributions = ({
{
id: ContributionsTab.ALL,
label: intl.formatMessage({ defaultMessage: 'All', id: 'zQvVDJ' }),
count: metadata?.account?.ALL.totalCount,
filter: {
...(onlyExpectedFunds ? { expectedFundsFilter: ExpectedFundsFilter.ALL_EXPECTED_FUNDS } : {}),
},
Expand Down

0 comments on commit 1f7da35

Please sign in to comment.