1
0
mirror of https://github.com/RSS-Bridge/rss-bridge.git synced 2025-07-31 05:40:24 +02:00

[formats] Rename variable 'data' to 'item'

This makes the intend of the variable more clear and is now
coherent with all Bridges
This commit is contained in:
logmanoriginal
2016-08-29 19:47:21 +02:00
parent a84016bcb6
commit cf146523be
6 changed files with 27 additions and 28 deletions

View File

@@ -17,12 +17,12 @@ class MrssFormat extends FormatAbstract{
$uri = $this->xml_encode(!empty($extraInfos['uri']) ? $extraInfos['uri'] : 'https://github.com/sebsauvage/rss-bridge');
$items = '';
foreach($this->getItems() as $data){
$itemAuthor = isset($data['author']) ? $this->xml_encode($data['author']) : '';
$itemTitle = strip_tags(isset($data['title']) ? $this->xml_encode($data['title']) : '');
$itemUri = isset($data['uri']) ? $this->xml_encode($data['uri']) : '';
$itemTimestamp = isset($data['timestamp']) ? $this->xml_encode(date(DATE_RFC2822, $data['timestamp'])) : '';
$itemContent = isset($data['content']) ? $this->xml_encode($this->sanitizeHtml($data['content'])) : '';
foreach($this->getItems() as $item){
$itemAuthor = isset($item['author']) ? $this->xml_encode($item['author']) : '';
$itemTitle = strip_tags(isset($item['title']) ? $this->xml_encode($item['title']) : '');
$itemUri = isset($item['uri']) ? $this->xml_encode($item['uri']) : '';
$itemTimestamp = isset($item['timestamp']) ? $this->xml_encode(date(DATE_RFC2822, $item['timestamp'])) : '';
$itemContent = isset($item['content']) ? $this->xml_encode($this->sanitizeHtml($item['content'])) : '';
$items .= <<<EOD
<item>