protected function AuditFilesNotOnServerBatchProcess::dispatch in Audit Files 4.x
Same name and namespace in other branches
- 8.3 src/Batch/AuditFilesNotOnServerBatchProcess.php \Drupal\auditfiles\Batch\AuditFilesNotOnServerBatchProcess::dispatch()
Processes file removal from file_usage that are not referenced in content.
Parameters
array $context: Batch context.
File
- src/
Batch/ AuditFilesNotOnServerBatchProcess.php, line 64
Class
- AuditFilesNotOnServerBatchProcess
- Process batch files.
Namespace
Drupal\auditfiles\BatchCode
protected function dispatch(array &$context) {
$this->notOnServer
->auditfilesNotOnServerBatchDeleteProcessFile($this->fileId);
$context['results'][] = Html::escape($this->fileId);
$context['message'] = new TranslatableMarkup('Processed file ID %file_id.', [
'%file_id' => $this->fileId,
]);
}