diff options
author | icewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-03-14 18:06:34 +0000 |
---|---|---|
committer | icewing <icewing@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-03-14 18:06:34 +0000 |
commit | 0fa665c8f465f2d3b85cb093d05f4d991516ca05 (patch) | |
tree | 026f1567f356f00ae51b50240865cdf8ec6b6e7e | |
parent | dc08082d7d5e3962c7c96a873ac1dd66891d5bb0 (diff) | |
download | elgg-0fa665c8f465f2d3b85cb093d05f4d991516ca05.tar.gz elgg-0fa665c8f465f2d3b85cb093d05f4d991516ca05.tar.bz2 |
Marcus Povey <marcus@dushka.co.uk>
* Removed error outputs
* Fixed languages
git-svn-id: https://code.elgg.org/elgg/trunk@232 36083f99-b078-4883-b0ff-0f9b5a30f544
-rw-r--r-- | engine/lib/access.php | 2 | ||||
-rw-r--r-- | engine/lib/languages.php | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/engine/lib/access.php b/engine/lib/access.php index 999d06a6e..d45520c07 100644 --- a/engine/lib/access.php +++ b/engine/lib/access.php @@ -61,7 +61,7 @@ $access_array = array();
if ($user_id == 0) $user_id = $_SESSION['id'];
- if ($site_id == 0) $site_id = $CONFIG->site_id;
+ if (($site_id == 0) && (isset($CONFIG->site_id))) $site_id = $CONFIG->site_id;
$user_id = (int) $user_id;
$site_id = (int) $site_id;
diff --git a/engine/lib/languages.php b/engine/lib/languages.php index f5abaaaa9..94956a3ca 100644 --- a/engine/lib/languages.php +++ b/engine/lib/languages.php @@ -58,11 +58,11 @@ global $CONFIG;
- if (empty($language))
+ if ((empty($language)) && (isset($CONFIG->language)))
$language = $CONFIG->language;
- if (isset($CONFIG->translations[$country_code][$message_key])) {
- return $CONFIG->translations[$country][$message_key];
+ if (isset($CONFIG->translations[$language][$message_key])) {
+ return $CONFIG->translations[$language][$message_key];
} else if (isset($CONFIG->translations["en"][$message_key])) {
return $CONFIG->translations["en"][$message_key];
}
|