Inline useless single use local variable

This commit is contained in:
Gary Gregory 2024-05-12 09:02:18 -04:00
parent 43214abc79
commit 75159111ff
1 changed files with 1 additions and 2 deletions

View File

@ -52,8 +52,7 @@ public abstract class AbstractMapEntryTest<K, V> {
public Map.Entry<K, V> makeKnownMapEntry(final K key, final V value) {
final Map<K, V> map = new HashMap<>(1);
map.put(key, value);
final Map.Entry<K, V> entry = map.entrySet().iterator().next();
return entry;
return map.entrySet().iterator().next();
}
/**