Participants are able to signup for the event without making any deposit.
The changeParticipationStatus() function allows individuals to signup (by setting their participation status to true) without making a deposit. This is because the else if statement just checks to see if the caller's status is currently false and if the deadline has passed. Since participant is a mapping(address => boolean)the default boolean value for any address will be false. This will allow any new callers to satisfy the first check !participant[msg.sender]. As long as the deadline has not passed the second check will also be satisfied resulting in the expression returning true. This will then allow the caller to set their particpation status to true while bypassing the deposit() function.
This will allow users to attend the event while not having to pay.
Foundry test:
Update the else if statment such that it verifies that the caller had previously made a deposit before changing their status from false back to true.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.