Fixed 'convertEntities' to links in RSS. Fixes #959

This commit is contained in:
xbuzz 2010-07-29 12:43:11 -07:00 committed by Juan Basso
parent 712ca6d5b5
commit f2f2987743

View file

@ -208,6 +208,13 @@ class RssHelper extends XmlHelper {
foreach ($elements as $key => $val) { foreach ($elements as $key => $val) {
$attrib = array(); $attrib = array();
$escape = true;
if (is_array($val) && isset($val['convertEntities'])) {
$escape = $val['convertEntities'];
unset($val['convertEntities']);
}
switch ($key) { switch ($key) {
case 'pubDate' : case 'pubDate' :
$val = $this->time($val); $val = $this->time($val);
@ -261,11 +268,6 @@ class RssHelper extends XmlHelper {
$val = null; $val = null;
break; break;
} }
$escape = true;
if (is_array($val) && isset($val['convertEntities'])) {
$escape = $val['convertEntities'];
unset($val['convertEntities']);
}
if (!is_null($val) && $escape) { if (!is_null($val) && $escape) {
$val = h($val); $val = h($val);
} }