From e8d31ad005ae02df5f1136d7f2a69b0d9875aeef Mon Sep 17 00:00:00 2001 From: Kousuke Saruta Date: Fri, 18 Aug 2023 05:46:16 +0900 Subject: [PATCH] Tweak. --- lang/java/avro/src/main/java/org/apache/avro/Schema.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lang/java/avro/src/main/java/org/apache/avro/Schema.java b/lang/java/avro/src/main/java/org/apache/avro/Schema.java index e86ae3e5b83..5434f18f852 100644 --- a/lang/java/avro/src/main/java/org/apache/avro/Schema.java +++ b/lang/java/avro/src/main/java/org/apache/avro/Schema.java @@ -717,7 +717,7 @@ public Name(String name, String space) { space = name.substring(0, lastDot); // get space from name this.name = validateName(name.substring(lastDot + 1)); } - this.space = "".equals(space) || space == null ? null : validateSpace(space); + this.space = space.isEmpty() || space == null ? null : validateSpace(space); this.full = (this.space == null) ? this.name : this.space + "." + this.name; }