Skip to content

Commit

Permalink
Removed placeholder for mac to work
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveMaier-IRT committed Jan 26, 2024
1 parent 1aea9d1 commit 0b5c8d5
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,18 +72,14 @@ public static class BallotValidationExtensions
/// </summary>
public static BallotValidationResult IsValid(
this CiphertextBallotSelection selection,
SelectionDescription description,
bool isPlaceholder = false)
SelectionDescription description)
{
return selection.ObjectId != description.ObjectId
? new BallotValidationResult(
$"Object Ids do not match for selection {selection.ObjectId} description {description.ObjectId}")
: selection.DescriptionHash != description.CryptoHash()
? new BallotValidationResult(
$"Description hashes do not match for selection {selection.ObjectId}")
: selection.IsPlaceholder != isPlaceholder
? new BallotValidationResult(
$"IsPlaceholder does not match for selection {selection.ObjectId}")
: new BallotValidationResult(true);
}

Expand Down Expand Up @@ -132,6 +128,8 @@ public static class BallotValidationExtensions
}
else
{
var placeholder = description.Placeholders
.FirstOrDefault(i => i.ObjectId == selectionDescription.ObjectId);
// validate the selection is valid
var result = selection.IsValid(selectionDescription);
if (!result.IsValid)
Expand Down

0 comments on commit 0b5c8d5

Please sign in to comment.