protected function decodePreVars(array &$pathSegments)
{
$requestVariables = array();
if (count($pathSegments) > 0) {
$preVarsList = array_filter((array) $this->configuration->get('preVars'));
$previousValue = '';
foreach ($preVarsList as $preVarConfiguration) {
$this->decodeSingleVariable($preVarConfiguration, $pathSegments, $requestVariables, $previousValue);
if (count($pathSegments) == 0) {
break;
}
}
if (isset($requestVariables['L'])) {
$this->detectedLanguageId = (int) $requestVariables['L'];
}
}
if (is_null($this->detectedLanguageId)) {
$this->detectedLanguageId = (int) $this->configuration->get('init/defaultLanguageUid');
}
return $requestVariables;
}