From 5270fc7030dd50ad12e4bdc17be58b4e3b3f4114 Mon Sep 17 00:00:00 2001 From: LukasDeco Date: Mon, 3 Jun 2024 14:07:50 -0600 Subject: [PATCH] fix: bug with limiting proposal fetching --- lib/client/indexer/proposals.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/client/indexer/proposals.ts b/lib/client/indexer/proposals.ts index 3d3528c..29e2ff3 100644 --- a/lib/client/indexer/proposals.ts +++ b/lib/client/indexer/proposals.ts @@ -54,7 +54,6 @@ export class FutarchyIndexerProposalsClient implements FutarchyProposalsClient { where: { dao: { dao_detail: { slug: { _eq: dao.slug } } } }, - limit: 1, order_by: [ { created_at: "desc" @@ -100,6 +99,7 @@ export class FutarchyIndexerProposalsClient implements FutarchyProposalsClient { market_type: true, twaps: { __args: { + limit: 1, order_by: [ { created_at: "desc" @@ -111,6 +111,7 @@ export class FutarchyIndexerProposalsClient implements FutarchyProposalsClient { }, prices: { __args: { + limit: 1, order_by: [ { created_at: "desc" @@ -370,7 +371,8 @@ export class FutarchyIndexerProposalsClient implements FutarchyProposalsClient { { created_at: "desc" } - ] + ], + limit: 1 }, token_amount: true, created_at: true, @@ -389,7 +391,8 @@ export class FutarchyIndexerProposalsClient implements FutarchyProposalsClient { { created_at: "desc" } - ] + ], + limit: 1 }, base_amount: true, quote_amount: true,