mirror of https://github.com/apache/lucene.git
use == for consistency w/ compareTo
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1245502 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
297f09d818
commit
0d14e2c89a
|
@ -83,7 +83,7 @@ public abstract class IndexCommit implements Comparable<IndexCommit> {
|
|||
public boolean equals(Object other) {
|
||||
if (other instanceof IndexCommit) {
|
||||
IndexCommit otherCommit = (IndexCommit) other;
|
||||
return otherCommit.getDirectory().equals(getDirectory()) && otherCommit.getGeneration() == getGeneration();
|
||||
return otherCommit.getDirectory() == getDirectory() && otherCommit.getGeneration() == getGeneration();
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue