Merge pull request #345 from SunghoLee/master
Fix the comparison method for ConstantKey
This commit is contained in:
commit
d13a38fbe1
|
@ -37,7 +37,7 @@ public final class ConstantKey<T> implements InstanceKey {
|
||||||
public boolean equals(Object obj) {
|
public boolean equals(Object obj) {
|
||||||
if (obj instanceof ConstantKey) {
|
if (obj instanceof ConstantKey) {
|
||||||
ConstantKey other = (ConstantKey) obj;
|
ConstantKey other = (ConstantKey) obj;
|
||||||
return value == null ? other.value == null : value.equals(other.value);
|
return valueClass.equals(other.valueClass) ? (value == null ? other.value == null : value.equals(other.value)) : false;
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue