1.3 KiB
1.3 KiB
public Election::removeCandidates
Description
public Election->removeCandidates ( CondorcetPHP\Condorcet\Candidate|array|string $candidates_input ): array
Remove candidates from an election.
Please note: You can't remove candidates after the first vote. An exception will be thrown.
candidates_input: CondorcetPHP\Condorcet\Candidate|array|string
- String matching candidate name
- CondorcetPHP\Condorcet\Candidate object
- Array populated by CondorcetPHP\Condorcet\Candidate
- Array populated by string matching candidate name.
Return value:
(array
) List of removed CondorcetPHP\Condorcet\Candidate object.
Throws:
CondorcetPHP\Condorcet\Throwable\CandidateDoesNotExistException
CondorcetPHP\Condorcet\Throwable\VotingHasStartedException