Skip to content

Commit

Permalink
[hotfix] TrialData.equals
Browse files Browse the repository at this point in the history
answer can be null
  • Loading branch information
joshuajeschek committed Jan 13, 2022
1 parent e02fcb8 commit 13ec5a6
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/main/java/github/weichware10/util/data/TrialData.java
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,11 @@ public boolean equals(Object other) {
return false;
}
TrialData that = (TrialData) (other);
return toolType.equals(that.toolType) && trialId.equals(that.trialId)
&& configId.equals(that.configId) && startTime.equals(that.startTime)
&& answer.equals(that.answer) && dataPoints.equals(that.dataPoints);
return toolType.equals(that.toolType)
&& (trialId == that.trialId || trialId.equals(that.trialId))
&& (configId == that.configId || configId.equals(that.configId))
&& startTime.equals(that.startTime)
&& (answer == that.answer || answer.equals(that.answer))
&& dataPoints.equals(that.dataPoints);
}
}

0 comments on commit 13ec5a6

Please sign in to comment.