You are here

function media_watermark_batch_finished in Media watermark 7

Perform tasks when a batch is complete.

Callback for batch_set().

Parameters

bool $success: A boolean indicating whether the batch operation successfully concluded.

int $results: The results from the batch process.

array $operations: The batch operations that remained unprocessed. Only relevant if $success is FALSE.

1 string reference to 'media_watermark_batch_finished'
media_watermark_prepare_batch in ./media_watermark.module
Batch operation: prepare batch to add watermarks to images.

File

./media_watermark.module, line 363
Watermark media module.

Code

function media_watermark_batch_finished($success, $results, $operations) {
  if ($success) {
    $count = count($results);
    drupal_set_message(t('Added watermarks to @count images', array(
      '@count' => $count,
    )));
  }
  else {
    drupal_set_message(t('Finished with errors.'), 'error');
  }
}