From f87f668197bf890295b3039b113a18d9352f0475 Mon Sep 17 00:00:00 2001 From: Matthew Whisenhunt Date: Thu, 15 Mar 2018 14:26:13 -0700 Subject: [PATCH] Cherrypick #371. --- .../src/main/java/com/google/api/client/util/ArrayMap.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/google-http-client/src/main/java/com/google/api/client/util/ArrayMap.java b/google-http-client/src/main/java/com/google/api/client/util/ArrayMap.java index 29d13b45f..079c8ff22 100644 --- a/google-http-client/src/main/java/com/google/api/client/util/ArrayMap.java +++ b/google-http-client/src/main/java/com/google/api/client/util/ArrayMap.java @@ -381,6 +381,7 @@ public Map.Entry next() { throw new NoSuchElementException(); } this.nextIndex++; + this.removed = false; return new Entry(index); } @@ -390,6 +391,7 @@ public void remove() { throw new IllegalArgumentException(); } ArrayMap.this.remove(index); + this.nextIndex--; this.removed = true; } }