diff --git a/apc.drush.inc b/apc.drush.inc index 67a0bfc..17ed16d 100644 --- a/apc.drush.inc +++ b/apc.drush.inc @@ -5,8 +5,7 @@ * Implements hook_drush_exit(). */ function apc_drush_exit() { - require_once DRUPAL_ROOT . '/includes/cache.inc'; - require_once dirname(__FILE__) . '/drupal_apc_cache.inc'; - - DrupalAPCCache::remoteFlush(); + if (class_exists('DrupalAPCCache')){ + DrupalAPCCache::remoteFlush(); + } }