From e02b0e95d6ddfff48b24a5499afed925ee8a4486 Mon Sep 17 00:00:00 2001 From: dennysq Date: Tue, 2 Jul 2019 02:02:05 -0500 Subject: [PATCH] override of equals method to delegate this functionality to the equals method of value object Validation Error: Value is not valid, this error is raising due to a bad implementation of object equals method --- impl/src/main/java/javax/faces/model/SelectItem.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/impl/src/main/java/javax/faces/model/SelectItem.java b/impl/src/main/java/javax/faces/model/SelectItem.java index a7ebfff1ce..fa0ad677bb 100644 --- a/impl/src/main/java/javax/faces/model/SelectItem.java +++ b/impl/src/main/java/javax/faces/model/SelectItem.java @@ -368,7 +368,11 @@ public boolean isNoSelectionOption() { public void setNoSelectionOption(boolean noSelectionOption) { this.noSelectionOption = noSelectionOption; } - + + @Override + public boolean equals(Object obj) { + return this.getValue().equals(obj.getValue()); + } }