From 96d3faf3cec5bf6f4fb275f173fbc8fd46d4e696 Mon Sep 17 00:00:00 2001 From: Ankit Kumar Ray <61264988+Ankit-69k@users.noreply.github.com> Date: Fri, 3 Oct 2025 23:47:18 +0530 Subject: [PATCH] fix(Grist Node): Allow filtering for numbers <= 0 (#20045) Co-authored-by: Shireen Missi <94372015+ShireenMissi@users.noreply.github.com> --- packages/nodes-base/nodes/Grist/GenericFunctions.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/nodes-base/nodes/Grist/GenericFunctions.ts b/packages/nodes-base/nodes/Grist/GenericFunctions.ts index 757826c77c6..d085579f9cd 100644 --- a/packages/nodes-base/nodes/Grist/GenericFunctions.ts +++ b/packages/nodes-base/nodes/Grist/GenericFunctions.ts @@ -68,7 +68,8 @@ export function parseSortProperties(sortProperties: GristSortProperties) { } export function isSafeInteger(val: number) { - return !isNaN(val) && val > Number.MIN_VALUE && val < Number.MAX_VALUE; + //used MIN_SAFE_INTEGER and MAX_SAFE_INTEGER instead of MIN_VALUE and MAX_VALUE to avoid edge cases + return !isNaN(val) && val > Number.MIN_SAFE_INTEGER && val < Number.MAX_SAFE_INTEGER; } export function parseFilterProperties(filterProperties: GristFilterProperties) {