aboutsummaryrefslogtreecommitdiffstats
path: root/upgrade.php
diff options
context:
space:
mode:
authorplegall <plg@piwigo.org>2012-04-07 21:00:51 +0000
committerplegall <plg@piwigo.org>2012-04-07 21:00:51 +0000
commitc59b052d7c84001fb267b38e24c20c51b33c6853 (patch)
tree1060afdda69dcbbed1dc4c23c9e93d863c4851c9 /upgrade.php
parent81e52ca60367de6ba7360a37922fbf14d4311ccf (diff)
merge r13955 from branch 2.3 to trunk
bug 2610 fixed: make sure the $_GET['lang'] or $_GET['language'] is in the list of available languages. git-svn-id: http://piwigo.org/svn/trunk@13956 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'upgrade.php')
-rw-r--r--upgrade.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/upgrade.php b/upgrade.php
index 55f2acf5a..dfb3c4c36 100644
--- a/upgrade.php
+++ b/upgrade.php
@@ -142,6 +142,11 @@ $languages = new languages('utf-8');
if (isset($_GET['language']))
{
$language = strip_tags($_GET['language']);
+
+ if (!in_array($language, array_keys($languages->fs_languages)))
+ {
+ $language = PHPWG_DEFAULT_LANGUAGE;
+ }
}
else
{