You are here

public function AdminPin::__construct in moderated content bulk publish 8

Same name and namespace in other branches
  1. 2.0.x src/AdminPin.php \Drupal\moderated_content_bulk_publish\AdminPin::__construct()
  2. 1.0.x src/AdminPin.php \Drupal\moderated_content_bulk_publish\AdminPin::__construct()

File

src/AdminPin.php, line 20

Class

AdminPin
A Helper Class to assist with the pin and unpin bulk action.

Namespace

Drupal\moderated_content_bulk_publish

Code

public function __construct($entity, $status) {
  $this->entity = $entity;
  if (!is_null($status)) {
    $this->status = $status;
  }
  $this->nid = $this->entity
    ->id();
}