You are here

public function ConsentAgreement::isPublished in General Data Protection Regulation 8

Same name and namespace in other branches
  1. 8.2 modules/gdpr_consent/src/Entity/ConsentAgreement.php \Drupal\gdpr_consent\Entity\ConsentAgreement::isPublished()
  2. 3.0.x modules/gdpr_consent/src/Entity/ConsentAgreement.php \Drupal\gdpr_consent\Entity\ConsentAgreement::isPublished()

Returns the Consent Agreement published status indicator.

Unpublished Consent Agreement are only visible to restricted users.

Return value

bool TRUE if the Consent Agreement is published.

Overrides ConsentAgreementInterface::isPublished

File

modules/gdpr_consent/src/Entity/ConsentAgreement.php, line 191

Class

ConsentAgreement
Defines the ConsentAgreement entity.

Namespace

Drupal\gdpr_consent\Entity

Code

public function isPublished() {
  return (bool) $this
    ->getEntityKey('status');
}