You are here

public function OgMembership::isActive in Organic groups 8

Returns TRUE if the OG membership is active.

Return value

bool TRUE if the OG membership is active, FALSE otherwise.

Overrides OgMembershipInterface::isActive

File

src/Entity/OgMembership.php, line 563

Class

OgMembership
The membership entity that connects a group and a user.

Namespace

Drupal\og\Entity

Code

public function isActive() : bool {
  return $this
    ->getState() === OgMembershipInterface::STATE_ACTIVE;
}