mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-23 16:33:17 +01:00
Fix vCard-parser for multible type parameters
This commit is contained in:
parent
f10e3a6ff3
commit
7c61ffa833
@ -641,11 +641,20 @@ class Horde_iCalendar {
|
||||
$paramValue = $param_parts[4][$key];
|
||||
if ($paramName == 'TYPE') {
|
||||
$paramValue = preg_split('/(?<!\\\\),/', $paramValue);
|
||||
if (count($paramValue) == 1) {
|
||||
$paramValue = $paramValue[0];
|
||||
}
|
||||
if (isset($params[$paramName])) {
|
||||
if (!is_array($params[$paramName])) {
|
||||
$params[$paramName] = array($params[$paramName]);
|
||||
}
|
||||
$params[$paramName] = array_merge($params[$paramName], $paramValue);
|
||||
} else {
|
||||
if (count($paramValue) == 1) {
|
||||
$paramValue = $paramValue[0];
|
||||
}
|
||||
$params[$paramName] = $paramValue;
|
||||
}
|
||||
} else {
|
||||
$params[$paramName] = $paramValue;
|
||||
}
|
||||
$params[$paramName] = $paramValue;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user