Fix exception in edge case for binding lists

This commit is contained in:
crschnick 2024-01-05 15:06:25 +00:00
parent 8e8186507a
commit 0742c0e2d2

View file

@ -304,8 +304,10 @@ public class BindingsHelper {
if (target.size() - 1 == newList.size() && targetSet.containsAll(newSet)) { if (target.size() - 1 == newList.size() && targetSet.containsAll(newSet)) {
var l = new HashSet<>(targetSet); var l = new HashSet<>(targetSet);
l.removeAll(newSet); l.removeAll(newSet);
target.remove(l.iterator().next()); if (l.size() > 0) {
return; target.remove(l.iterator().next());
return;
}
} }
// Other cases are more difficult // Other cases are more difficult