From 6c3e94e385150635f13928fbe92fd5ccc62fa9e4 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sun, 20 May 2001 16:49:27 +0000 Subject: - Fixed small glitch in locale.module. --- modules/locale.module | 2 +- modules/locale/locale.module | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/locale.module b/modules/locale.module index 1e2a074c8..40718a8f0 100644 --- a/modules/locale.module +++ b/modules/locale.module @@ -100,7 +100,7 @@ function locale_admin() { function locale($string) { global $locale; - if ($locale) { + if (variable_get("locale", 0)) { $result = db_query("SELECT id, $locale FROM locales WHERE STRCMP(string, '". addslashes($string) ."') = 0"); if ($translation = db_fetch_object($result)) $string = ($translation->$locale) ? check_output($translation->$locale) : $string; else db_query("INSERT INTO locales (string, location) VALUES ('". addslashes($string) ."', '". check_input(getenv("REQUEST_URI")) ."')"); diff --git a/modules/locale/locale.module b/modules/locale/locale.module index 1e2a074c8..40718a8f0 100644 --- a/modules/locale/locale.module +++ b/modules/locale/locale.module @@ -100,7 +100,7 @@ function locale_admin() { function locale($string) { global $locale; - if ($locale) { + if (variable_get("locale", 0)) { $result = db_query("SELECT id, $locale FROM locales WHERE STRCMP(string, '". addslashes($string) ."') = 0"); if ($translation = db_fetch_object($result)) $string = ($translation->$locale) ? check_output($translation->$locale) : $string; else db_query("INSERT INTO locales (string, location) VALUES ('". addslashes($string) ."', '". check_input(getenv("REQUEST_URI")) ."')"); -- cgit v1.2.3