summaryrefslogtreecommitdiff
path: root/modules/gallery/controllers/upgrader.php
diff options
context:
space:
mode:
authorTim Almdal <tnalmdal@shaw.ca>2009-10-26 09:35:41 -0700
committerTim Almdal <tnalmdal@shaw.ca>2009-10-26 09:35:41 -0700
commite4eedbce2298535540cb651d75ba6f1bf42cf02b (patch)
tree767cc2f81ef2abfacb0d5d3a8df464a65cf65c45 /modules/gallery/controllers/upgrader.php
parent6fb116c53be947018e02de933d724273e76a251d (diff)
Change the upgrader so that it never deactivactes the gallery nor the current identity provider modules. Call module::deactive to truly deactivate the module.
Diffstat (limited to 'modules/gallery/controllers/upgrader.php')
-rw-r--r--modules/gallery/controllers/upgrader.php10
1 files changed, 7 insertions, 3 deletions
diff --git a/modules/gallery/controllers/upgrader.php b/modules/gallery/controllers/upgrader.php
index 1aa607ef..a86e8af9 100644
--- a/modules/gallery/controllers/upgrader.php
+++ b/modules/gallery/controllers/upgrader.php
@@ -56,9 +56,13 @@ class Upgrader_Controller extends Controller {
access::forbidden();
}
- // Upgrade gallery and user first
- module::upgrade("gallery");
- module::upgrade("user");
+ $available = module::available();
+ // Upgrade gallery first
+ $gallery = $available["gallery"];
+ if ($gallery->code_version != $gallery->version) {
+ module::upgrade("gallery");
+ module::activate("gallery");
+ }
// Then upgrade the rest
foreach (module::available() as $id => $module) {