Alternator icon indicating copy to clipboard operation
Alternator copied to clipboard

Attributes comparison in AlternatorDBHandler doesn't work

Open yelis913 opened this issue 12 years ago • 1 comments

AlternatorDBHandler.java:424

(value.getValue().getN() != null && !item.get(key).equals(value.getValue().getN())) || (value.getValue().getS() != null && !item.get(key).equals(value.getValue().getS())) || (value.getValue().getNS() != null && !item.get(key).equals(value.getValue().getNS())) || (value.getValue().getSS() != null && !item.get(key).equals(value.getValue().getSS()))

There seems to be a wrong pattern here, because item.get(key) produces an AttributeValue which is then compared to an unwrapped value (e.g. String), so equals() always fails.

yelis913 avatar Aug 19 '13 08:08 yelis913

Fixed in commit https://github.com/yelis913/Alternator/commit/c82daad67d1d08b886666881d025d06720ecc046

Will be in 0.6.4 release.

Cheers.

mboudreau avatar Aug 19 '13 10:08 mboudreau