Browse Source

Update comment and get rid of related drupal_is_cli() call.

pull/597/head
Adam Vessey 10 years ago
parent
commit
d5722c5f4e
  1. 10
      islandora.module

10
islandora.module

@ -2105,7 +2105,10 @@ function islandora_conditionally_clear_cache() {
$functions = array( $functions = array(
// Object changes in response to a form. // Object changes in response to a form.
'form_execute_handlers' => 'islandora_clear_cache_all', 'form_execute_handlers' => 'islandora_clear_cache_all',
// Object changes in response to a batch. // Object changes in response to a batch. Note that this will not match on
// a drush batch, as drush uses a different set of functions to run
// batches. We intentionally do not clear batches in response to drush
// batches, since they are not in response to GUI actions.
'_batch_process' => 'islandora_schedule_cache_clear_for_batch', '_batch_process' => 'islandora_schedule_cache_clear_for_batch',
); );
@ -2145,10 +2148,9 @@ function islandora_schedule_cache_clear_for_batch() {
$scheduled = isset($scheduled) || isset($batch['islandora_cache_clear_scheduled']); $scheduled = isset($scheduled) || isset($batch['islandora_cache_clear_scheduled']);
if ($scheduled || !isset($batch['id']) || drupal_is_cli()) { if ($scheduled || !isset($batch['id'])) {
// We do not wish to do anything if we are either already scheduled or the // We do not wish to do anything if we are either already scheduled or the
// batch is not running. Also, if the batch is running on the CLI (via drush // batch is not running.
// or otherwise).
return; return;
} }

Loading…
Cancel
Save