From b536b9ed9fa47e9f7004e10c1bb5bacc35d71fdf Mon Sep 17 00:00:00 2001 From: Mickael Stanislas Date: Fri, 9 Jun 2023 10:38:18 +0200 Subject: [PATCH] fix: attributeIsDivisibleByAnInteger bad check if value IsNull and IsUnknown --- int64validator/attribute_is_divisible_by_an_integer.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/int64validator/attribute_is_divisible_by_an_integer.go b/int64validator/attribute_is_divisible_by_an_integer.go index 6b055b0..b27987c 100644 --- a/int64validator/attribute_is_divisible_by_an_integer.go +++ b/int64validator/attribute_is_divisible_by_an_integer.go @@ -32,7 +32,7 @@ func (validator attributeIsDivisibleByAnInteger) ValidateInt64( res *validator.Int64Response, ) { // If attribute configuration is not null or unknown, there is nothing else to validate - if req.ConfigValue.IsNull() && req.ConfigValue.IsUnknown() { + if req.ConfigValue.IsNull() || req.ConfigValue.IsUnknown() { return }