Browse Source

Merge pull request #430 from nigelgbanks/7.x-uninstall-issues

Can now uninstall islandora and dependant solution packs.
pull/433/head
Jonathan Green 11 years ago
parent
commit
5a1c1d35e6
  1. 11
      includes/solution_packs.inc
  2. 1
      includes/tuque.inc
  3. 1
      islandora.module

11
includes/solution_packs.inc

@ -28,7 +28,16 @@ function islandora_solution_packs_get_required_objects($module = NULL) {
if (!$required_objects) {
$connection = islandora_get_tuque_connection();
$required_objects = module_invoke_all('islandora_required_objects', $connection);
if (isset($module)) {
// The module may be disabled when this function runs, as modules must be
// disabled before they can be uninstalled. We must manually load the
// module file to use it's islandora_required_objects hook.
module_load_include('module', $module, $module);
$required_objects = module_invoke($module, 'islandora_required_objects', $connection);
}
else {
$required_objects = module_invoke_all('islandora_required_objects', $connection);
}
}
if ($module !== NULL) {

1
includes/tuque.inc

@ -85,6 +85,7 @@ class IslandoraTuque {
}
if (self::exists()) {
module_load_include('inc', 'islandora', 'includes/tuque_wrapper');
$this->connection = new IslandoraRepositoryConnection($url, $user_string, $pass_string);
$this->connection->reuseConnection = TRUE;
$this->api = new IslandoraFedoraApi($this->connection);

1
islandora.module

@ -1113,6 +1113,7 @@ function islandora_default_islandora_printer_object($object, $alter) {
* A IslandoraTuque instance
*/
function islandora_get_tuque_connection($user = NULL, $url = NULL) {
module_load_include('inc', 'islandora', 'includes/tuque');
$tuque = &drupal_static(__FUNCTION__);
if (!$tuque) {
if (IslandoraTuque::exists()) {

Loading…
Cancel
Save