File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
core-api/src/main/java/com/optimizely/ab/config/audience/match Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -108,6 +108,11 @@ public String toString() {
108108 return ret .toString ();
109109 }
110110
111+ @ Override
112+ public int hashCode () {
113+ return toString ().hashCode ();
114+ }
115+
111116 @ Override
112117 public boolean equals (Object other ) {
113118 if (this == other ) {
@@ -117,7 +122,9 @@ public boolean equals(Object other) {
117122 return false ;
118123 }
119124 SemanticVersion ov = (SemanticVersion ) other ;
120- if (ov .major != major || ov .minor != minor || ov .patch != patch ) {
125+ if (!ov .major .equals (major ) ||
126+ !ov .minor .equals (minor ) ||
127+ !ov .patch .equals (patch )) {
121128 return false ;
122129 }
123130 if (ov .preRelease .length != preRelease .length ) {
You can’t perform that action at this time.
0 commit comments