mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-07-29 21:00:14 +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:
@@ -16,7 +16,7 @@ abstract class FormatAbstract implements FormatInterface{
|
||||
protected
|
||||
$contentType,
|
||||
$charset,
|
||||
$datas,
|
||||
$items,
|
||||
$extraInfos
|
||||
;
|
||||
|
||||
@@ -48,17 +48,16 @@ abstract class FormatAbstract implements FormatInterface{
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function setItems(array $datas){
|
||||
$this->datas = $datas;
|
||||
public function setItems(array $items){
|
||||
$this->items = $items;
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getItems(){
|
||||
if( !is_array($this->datas) ){
|
||||
if(!is_array($this->items))
|
||||
throw new \LogicException('Feed the ' . get_class($this) . ' with "setItems" method before !');
|
||||
}
|
||||
|
||||
return $this->datas;
|
||||
return $this->items;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user