From 971bc51e84f2224f2752ddb17eca991befa46369 Mon Sep 17 00:00:00 2001 From: tunghp2002 Date: Mon, 6 Jan 2025 08:42:30 +0700 Subject: [PATCH] [Fix] Not autoselect when 1 maxcount --- packages/extension-koni-ui/src/utils/earning.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/extension-koni-ui/src/utils/earning.ts b/packages/extension-koni-ui/src/utils/earning.ts index 69f5bcb0cb..2caa0900f2 100644 --- a/packages/extension-koni-ui/src/utils/earning.ts +++ b/packages/extension-koni-ui/src/utils/earning.ts @@ -82,7 +82,7 @@ export function autoSelectValidatorOptimally (validators: ValidatorInfo[], maxCo if (result.length >= maxCount) { shuffle(result); - return result.slice(0, maxCount - 1); + return result.slice(0, maxCount); } shuffle(notPreSelected);