This is still is required; search by ID seems still broken.

This commit is contained in:
Bradley M. Kuhn 2022-06-21 10:42:32 -07:00
parent bdd100540a
commit 71c0bd28aa

View file

@ -29,7 +29,12 @@ my $sp = new Supporters($dbh, ['none']);
my $found = 0; my $found = 0;
my(@supporterIds); my(@supporterIds);
die "Can only search on id, ledgerEntityId, emailAddress" unless $CRITERION =~ /^(ledgerEntityId|emailAddress|id)$/; die "Can only search on id, ledgerEntityId, emailAddress" unless $CRITERION =~ /^(ledgerEntityId|emailAddress|id)$/;
@supporterIds = $sp->findDonor({$CRITERION => $SEARCH_PARAMETER }); if ($CRITERION eq 'id') {
push(@supporterIds, $SEARCH_PARAMETER);
} else {
@supporterIds = $sp->findDonor({$CRITERION => $SEARCH_PARAMETER });
}
my @requestTypes = $sp->getRequestType(); my @requestTypes = $sp->getRequestType();
foreach my $id (@supporterIds) { foreach my $id (@supporterIds) {
$found = 1; $found = 1;