summaryrefslogtreecommitdiff
path: root/modules/search
diff options
context:
space:
mode:
authorTim Almdal <tnalmdal@shaw.ca>2009-09-16 22:23:32 -0700
committerTim Almdal <tnalmdal@shaw.ca>2009-09-16 22:23:32 -0700
commit9d76797b17d65540a903ef37eee6edca3e83108b (patch)
tree0040acb8746d68e21f06ab265493f4054e525908 /modules/search
parent5490057480f17e5810cf8b9e558769ebd74d4b27 (diff)
Changed the search module installer to explicitly specify MyISAM as the database type. Changed the packager to not remove the engine specification if the table is search_records. Fixes Ticket #774
Diffstat (limited to 'modules/search')
-rw-r--r--modules/search/helpers/search_installer.php10
-rw-r--r--modules/search/module.info2
2 files changed, 11 insertions, 1 deletions
diff --git a/modules/search/helpers/search_installer.php b/modules/search/helpers/search_installer.php
index 10d8211f..096f46c7 100644
--- a/modules/search/helpers/search_installer.php
+++ b/modules/search/helpers/search_installer.php
@@ -28,6 +28,7 @@ class search_installer {
PRIMARY KEY (`id`),
KEY(`item_id`),
FULLTEXT INDEX (`data`))
+ ENGINE=MYISAM
DEFAULT CHARSET=utf8;");
module::set_version("search", 1);
}
@@ -47,4 +48,13 @@ class search_installer {
static function uninstall() {
Database::instance()->query("DROP TABLE {search_records}");
}
+
+ static function upgrade($version) {
+ $db = Database::instance();
+ if ($version == 1) {
+ $db->query("ALTER TABLE {search_records} ENGINE=MYISAM");
+ module::set_version("search", 2);
+ }
+ }
+
}
diff --git a/modules/search/module.info b/modules/search/module.info
index f417c4fa..2f2ebdf1 100644
--- a/modules/search/module.info
+++ b/modules/search/module.info
@@ -1,3 +1,3 @@
name = "Search"
description = "Allows users to search their Gallery"
-version = 1
+version = 2