From 3e5ccb171a56b3278f7123638631b945ec52e5cb Mon Sep 17 00:00:00 2001 From: Andrey Litvitski <120543954+panic08@users.noreply.github.com> Date: Sun, 20 Oct 2024 19:48:09 +0300 Subject: [PATCH] Change the use of == operator to isEmpty() in JsonObject (#2768) --- gson/src/main/java/com/google/gson/JsonObject.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gson/src/main/java/com/google/gson/JsonObject.java b/gson/src/main/java/com/google/gson/JsonObject.java index 408d22685d..3bde741190 100644 --- a/gson/src/main/java/com/google/gson/JsonObject.java +++ b/gson/src/main/java/com/google/gson/JsonObject.java @@ -164,7 +164,7 @@ public int size() { * @since 2.10.1 */ public boolean isEmpty() { - return members.size() == 0; + return members.isEmpty(); } /**