You are here

public function LinkExtractorBatch::batchFinished in Link checker 8

Finished callback for batch.

File

src/LinkExtractorBatch.php, line 222

Class

LinkExtractorBatch
Helper service to handle extraction index.

Namespace

Drupal\linkchecker

Code

public function batchFinished($success) {
  if ($success) {
    $this
      ->messenger()
      ->addStatus($this
      ->t('Links were successfully extracted.'));
  }
  else {
    $this
      ->messenger()
      ->addError($this
      ->t('Links were not extracted.'));
  }
}