summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2003-10-09 19:19:07 +0000
committerDries Buytaert <dries@buytaert.net>2003-10-09 19:19:07 +0000
commitb11d99fe168aeabfc34bd4f8d0e55c0d82f08e48 (patch)
tree3d046aafaecf13b927e6767bdae60cc0d5c8a57f
parent1a5fcacdd9d6831a01d8eab8f49674c59c25cb80 (diff)
downloadbrdo-b11d99fe168aeabfc34bd4f8d0e55c0d82f08e48.tar.gz
brdo-b11d99fe168aeabfc34bd4f8d0e55c0d82f08e48.tar.bz2
- Fixed bug #3564: missing check in locale module.
-rw-r--r--modules/locale.module2
-rw-r--r--modules/locale/locale.module2
2 files changed, 2 insertions, 2 deletions
diff --git a/modules/locale.module b/modules/locale.module
index 738dcfc17..18baa7dd6 100644
--- a/modules/locale.module
+++ b/modules/locale.module
@@ -340,7 +340,7 @@ function locale($string) {
$locale_t = unserialize($cache->data);
}
- if (array_key_exists($string, $locale_t)) {
+ if (is_array($locale_t) && array_key_exists($string, $locale_t)) {
$string = $locale_t[$string];
}
else {
diff --git a/modules/locale/locale.module b/modules/locale/locale.module
index 738dcfc17..18baa7dd6 100644
--- a/modules/locale/locale.module
+++ b/modules/locale/locale.module
@@ -340,7 +340,7 @@ function locale($string) {
$locale_t = unserialize($cache->data);
}
- if (array_key_exists($string, $locale_t)) {
+ if (is_array($locale_t) && array_key_exists($string, $locale_t)) {
$string = $locale_t[$string];
}
else {