Commit 8e26f2db authored by Thomas Löffler's avatar Thomas Löffler

Parse language key to int before redirecting

parent 153e13f1
Pipeline #605 failed with stage
in 2 minutes and 31 seconds
......@@ -122,7 +122,7 @@ class LanguageDetection extends AbstractPlugin
if (isset($languageSessionKey)) {
// Can redirect only in one tree method for now
if ($this->conf['useOneTreeMethod'] && is_numeric($languageSessionKey)) {
$this->doRedirect($languageSessionKey, $referrer);
$this->doRedirect((int)$languageSessionKey, $referrer);
return '';
}
......@@ -321,7 +321,7 @@ class LanguageDetection extends AbstractPlugin
}
if ($preferredLanguageOrPageUid !== false) {
$this->doRedirect($preferredLanguageOrPageUid, $referrer);
$this->doRedirect((int)$preferredLanguageOrPageUid, $referrer);
}
return '';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment