Skip to content

Commit fae4829

Browse files
committed
LastRecentlyUsed: fix bug in replace function
Closes #453.
1 parent bdd6b1a commit fae4829

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/org/scijava/util/LastRecentlyUsed.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ public boolean replace(final int index, T newValue) {
143143
throw new IllegalArgumentException("No current entry at position " +
144144
index);
145145
}
146-
if (newValue.equals(previous)) return false;
146+
if (newValue.equals(previousValue)) return false;
147147
map.remove(previousValue);
148148
map.put(newValue, index);
149149
entries[index] = newValue;

0 commit comments

Comments
 (0)