Skip to content

Commit

Permalink
Add updated file.
Browse files Browse the repository at this point in the history
  • Loading branch information
thisismeonmounteverest committed May 18, 2024
1 parent 640e532 commit 49ed392
Showing 1 changed file with 21 additions and 1 deletion.
22 changes: 21 additions & 1 deletion src/Entity/Member.php
Original file line number Diff line number Diff line change
Expand Up @@ -1127,6 +1127,11 @@ public function getFields(): Collection
return $this->fields;
}

public function getMemberFields(): array
{
return $this->memberFields;
}

public function addVolunteerRight(RightVolunteer $volunteerRight): self
{
if (!$this->volunteerRights->contains($volunteerRight)) {
Expand Down Expand Up @@ -1332,14 +1337,29 @@ public function isBanned(): bool

public function isDeniedAccess(): bool
{
return !$this->isBrowsable();
return !in_array(
$this->status,
[
MemberStatusType::ACTIVE,
MemberStatusType::OUT_OF_REMIND,
MemberStatusType::ACCOUNT_ACTIVATED,
MemberStatusType::MAIL_CONFIRMED,
MemberStatusType::AWAITING_MAIL_CONFIRMATION,
],
true
);
}

public function isNotConfirmedYet(): bool
{
return MemberStatusType::AWAITING_MAIL_CONFIRMATION === $this->status;
}

public function didConfirmMailAddress(): bool
{
return MemberStatusType::MAIL_CONFIRMED === $this->status;
}

public function isFirstnameShown(): bool
{
return ($this->hideAttribute & self::MEMBER_FIRSTNAME_HIDDEN) !== self::MEMBER_FIRSTNAME_HIDDEN;
Expand Down

0 comments on commit 49ed392

Please sign in to comment.