summaryrefslogtreecommitdiff
path: root/modules/gallery/helpers
diff options
context:
space:
mode:
Diffstat (limited to 'modules/gallery/helpers')
-rw-r--r--modules/gallery/helpers/gallery.php2
-rw-r--r--modules/gallery/helpers/gallery_installer.php12
-rw-r--r--modules/gallery/helpers/gallery_task.php2
-rw-r--r--modules/gallery/helpers/locales.php1
4 files changed, 15 insertions, 2 deletions
diff --git a/modules/gallery/helpers/gallery.php b/modules/gallery/helpers/gallery.php
index 84f8a7fb..a43b180b 100644
--- a/modules/gallery/helpers/gallery.php
+++ b/modules/gallery/helpers/gallery.php
@@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class gallery_Core {
- const VERSION = "3.0 git (pre-RC1)";
+ const VERSION = "3.0 RC1 (Santa Fe)";
/**
* If Gallery is in maintenance mode, then force all non-admins to get routed to a "This site is
diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php
index b594ddcf..6f8a6688 100644
--- a/modules/gallery/helpers/gallery_installer.php
+++ b/modules/gallery/helpers/gallery_installer.php
@@ -32,6 +32,10 @@ class gallery_installer {
PRIMARY KEY (`id`))
DEFAULT CHARSET=utf8;");
+ // Using a simple index instead of a unique key for the
+ // key column to avoid handling of concurrency issues
+ // on insert. Thus allowing concurrent inserts on the
+ // same cache key, as does Memcache / xcache.
$db->query("CREATE TABLE {caches} (
`id` int(9) NOT NULL auto_increment,
`key` varchar(255) NOT NULL,
@@ -39,6 +43,7 @@ class gallery_installer {
`expiration` int(9) NOT NULL,
`cache` longblob,
PRIMARY KEY (`id`),
+ KEY (`key`),
KEY (`tags`))
DEFAULT CHARSET=utf8;");
@@ -290,7 +295,7 @@ class gallery_installer {
module::set_var("gallery", "credits", (string) $powered_by_string);
module::set_var("gallery", "simultaneous_upload_limit", 5);
module::set_var("gallery", "admin_area_timeout", 90 * 60);
- module::set_version("gallery", 29);
+ module::set_version("gallery", 30);
}
static function upgrade($version) {
@@ -545,6 +550,11 @@ class gallery_installer {
module::set_var("gallery", "credits", "Powered by <a href=\"%url\">%gallery_version</a>");
module::set_version("gallery", $version = 29);
}
+
+ if ($version == 29) {
+ $db->query("ALTER TABLE {caches} ADD KEY (`key`);");
+ module::set_version("gallery", $version = 30);
+ }
}
static function uninstall() {
diff --git a/modules/gallery/helpers/gallery_task.php b/modules/gallery/helpers/gallery_task.php
index 3e6278e5..617f7f48 100644
--- a/modules/gallery/helpers/gallery_task.php
+++ b/modules/gallery/helpers/gallery_task.php
@@ -201,6 +201,8 @@ class gallery_task_Core {
$total = $num_fetched + $num_remaining;
$task->percent_complete = 70 + 30 * ((float) $num_fetched / $total);
} else {
+ Gallery_I18n::clear_cache();
+
$task->done = true;
$task->state = "success";
$task->status = t("Translations installed/updated");
diff --git a/modules/gallery/helpers/locales.php b/modules/gallery/helpers/locales.php
index e72d7ed9..62b08fb9 100644
--- a/modules/gallery/helpers/locales.php
+++ b/modules/gallery/helpers/locales.php
@@ -81,6 +81,7 @@ class locales_Core {
$l["eu_ES"] = "Euskara"; // Basque
$l["fa_IR"] = "فارس"; // Farsi
$l["fi_FI"] = "Suomi"; // Finnish
+ $l["fo_FO"] = "Føroyskt"; // Faroese
$l["fr_FR"] = "Français"; // French
$l["ga_IE"] = "Gaeilge"; // Irish
$l["he_IL"] = "עברית"; // Hebrew