From 17f7a1f4ac2e7660028f76fc22b112c4434b5894 Mon Sep 17 00:00:00 2001 From: ZhouXY108 Date: Mon, 3 Apr 2023 23:56:32 +0800 Subject: [PATCH] fix bug. --- src/main/java/xyz/zhouxy/plusone/validator/StringValidator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/xyz/zhouxy/plusone/validator/StringValidator.java b/src/main/java/xyz/zhouxy/plusone/validator/StringValidator.java index b833533..7996810 100644 --- a/src/main/java/xyz/zhouxy/plusone/validator/StringValidator.java +++ b/src/main/java/xyz/zhouxy/plusone/validator/StringValidator.java @@ -185,7 +185,7 @@ public class StringValidator extends PropertyValidator exceptionCreator) { withRule(value -> { if (value == null) { - return false; + return true; } return value.isEmpty(); }, exceptionCreator);