Customfields:

- fix saving of @filename style options got automatically converted to label=@value style
This commit is contained in:
Nathan Gray 2015-04-21 16:13:10 +00:00
parent 4ea0638267
commit 7c2b6a44f8

View File

@ -318,12 +318,19 @@ class customfields
if (!empty($content['cf_values']))
{
$values = array();
if($content['cf_values'][0] === '@')
{
$values['@'] = substr($content['cf_values'], $content['cf_values'][1] === '=' ? 2:1);
}
else
{
foreach(explode("\n",$content['cf_values']) as $line)
{
list($var,$value) = explode('=',trim($line),2);
$var = trim($var);
$values[$var] = empty($value) ? $var : $value;
}
}
$content['cf_values'] = $values;
}
$update_content = array();