You are here

public function Batch::process in Organic groups 8

Starts the deletion process.

Overrides OgDeleteOrphansInterface::process

File

src/Plugin/OgDeleteOrphans/Batch.php, line 24

Class

Batch
Performs a batch deletion of orphans.

Namespace

Drupal\og\Plugin\OgDeleteOrphans

Code

public function process() {
  $queue = $this
    ->getQueue();
  $item = $queue
    ->claimItem(0);
  $data = $item->data;
  $this
    ->deleteOrphan($data['type'], $data['id']);
  $queue
    ->deleteItem($item);
}