Skip to content

Commit

Permalink
fix: revert FP random sort
Browse files Browse the repository at this point in the history
  • Loading branch information
jrwbabylonlab committed Dec 5, 2024
1 parent 54ea2e9 commit 1d8c9e1
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 11 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "simple-staking",
"version": "0.3.14",
"version": "0.3.15",
"private": true,
"scripts": {
"dev": "next dev",
Expand Down
7 changes: 0 additions & 7 deletions src/app/api/getFinalityProviders.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,9 @@ interface DescriptionAPI {

export const getFinalityProviders = async (
key: string,
sort: string,
): Promise<PaginatedFinalityProviders> => {
// const limit = 100;
// const reverse = false;

const params = {
pagination_key: encode(key),
sort,
// "pagination_reverse": reverse,
// "pagination_limit": limit,
};

const response = await apiWrapper(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const FinalityProviders: React.FC<FinalityProvidersProps> = ({
isRefetchError: isRefetchFinalityProvidersError,
} = useInfiniteQuery({
queryKey: ["finality providers"],
queryFn: ({ pageParam = "" }) => getFinalityProviders(pageParam, "random"),
queryFn: ({ pageParam = "" }) => getFinalityProviders(pageParam),
getNextPageParam: (lastPage) =>
lastPage?.pagination?.next_key !== ""
? lastPage?.pagination?.next_key
Expand Down

0 comments on commit 1d8c9e1

Please sign in to comment.