function taxonomy_orphanage_batch_finished in Taxonomy Orphanage 7
Finished batch callback.
1 string reference to 'taxonomy_orphanage_batch_finished'
- taxonomy_orphanage_roundup in ./
taxonomy_orphanage.module - Looks for orphaned taxonomy references and removes them.
File
- ./
taxonomy_orphanage.batch.inc, line 76 - Batch callbacks for taxonomy_orphanage.
Code
function taxonomy_orphanage_batch_finished($success, $results, $operations) {
if ($success) {
$count = isset($results['count']) ? $results['count'] : 0;
$msg = t('@count orphaned taxonomy references have been removed.', array(
'@count' => $count,
));
$dsm_type = 'status';
$log_type = WATCHDOG_INFO;
}
else {
$msg = t('There was a problem removing orphaned taxonomy terms.');
$dsm_type = 'error';
$log_type = WATCHDOG_ERROR;
}
watchdog('taxonomy_orphanage', $msg, array(), $log_type);
if (isset($results['display_finished']) && $results['display_finished']) {
drupal_set_message($msg, $dsm_type);
}
}