mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-07-30 15:44:47 +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:
parent
a84016bcb6
commit
cf146523be
6 changed files with 27 additions and 28 deletions
|
@ -19,12 +19,12 @@ class AtomFormat extends FormatAbstract{
|
|||
$uri = $this->xml_encode($uri);
|
||||
|
||||
$entries = '';
|
||||
foreach($this->getItems() as $data){
|
||||
$entryAuthor = isset($data['author']) ? $this->xml_encode($data['author']) : '';
|
||||
$entryTitle = isset($data['title']) ? $this->xml_encode($data['title']) : '';
|
||||
$entryUri = isset($data['uri']) ? $this->xml_encode($data['uri']) : '';
|
||||
$entryTimestamp = isset($data['timestamp']) ? $this->xml_encode(date(DATE_ATOM, $data['timestamp'])) : '';
|
||||
$entryContent = isset($data['content']) ? $this->xml_encode($this->sanitizeHtml($data['content'])) : '';
|
||||
foreach($this->getItems() as $item){
|
||||
$entryAuthor = isset($item['author']) ? $this->xml_encode($item['author']) : '';
|
||||
$entryTitle = isset($item['title']) ? $this->xml_encode($item['title']) : '';
|
||||
$entryUri = isset($item['uri']) ? $this->xml_encode($item['uri']) : '';
|
||||
$entryTimestamp = isset($item['timestamp']) ? $this->xml_encode(date(DATE_ATOM, $item['timestamp'])) : '';
|
||||
$entryContent = isset($item['content']) ? $this->xml_encode($this->sanitizeHtml($item['content'])) : '';
|
||||
$entries .= <<<EOD
|
||||
|
||||
<entry>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue