From 8fb56abf034dd1f5c561e7af12bf6e097a3de6f6 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Tue, 15 Jun 2010 16:30:02 -0700 Subject: Bump the organize module to version 2, and check to make sure that the REST module is active. --- modules/organize/helpers/organize_installer.php | 14 ++++++++++++++ modules/organize/module.info | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) (limited to 'modules') diff --git a/modules/organize/helpers/organize_installer.php b/modules/organize/helpers/organize_installer.php index 7585438f..bbe6fc65 100644 --- a/modules/organize/helpers/organize_installer.php +++ b/modules/organize/helpers/organize_installer.php @@ -22,6 +22,20 @@ class organize_installer { site_status::clear("organize_needs_rest"); } + static function upgrade($version) { + if ($version == 1) { + if (!module::is_active("rest")) { + site_status::warning( + t("The Organize module requires the Rest module. " . + "Activate the Rest module now", + array("url" => html::mark_clean(url::site("admin/modules")))), + "organize_needs_rest"); + } + + module::set_version("organize", $version = 2); + } + } + static function can_activate() { $messages = array(); if (!module::is_active("rest")) { diff --git a/modules/organize/module.info b/modules/organize/module.info index 5c6b1de0..d7199571 100644 --- a/modules/organize/module.info +++ b/modules/organize/module.info @@ -1,3 +1,3 @@ name = "Organize" description = "Organize your gallery by apply tags or moving images" -version = 1 +version = 2 -- cgit v1.2.3