mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-08-07 00:56:34 +02:00
refactor: FeedExpander::parseItem() descendants (#3744)
This commit is contained in:
@@ -43,9 +43,9 @@ class CNETFranceBridge extends FeedExpander
|
||||
$this->collectExpandableDatas('https://www.cnetfrance.fr/feeds/rss/news/');
|
||||
}
|
||||
|
||||
protected function parseItem($feedItem)
|
||||
protected function parseItem($item)
|
||||
{
|
||||
$item = parent::parseItem($feedItem);
|
||||
$item = parent::parseItem($item);
|
||||
|
||||
foreach ($this->bannedTitle as $term) {
|
||||
if (preg_match('/' . $term . '/mi', $item['title']) === 1) {
|
||||
@@ -54,8 +54,7 @@ class CNETFranceBridge extends FeedExpander
|
||||
}
|
||||
|
||||
foreach ($this->bannedURL as $term) {
|
||||
$preg_match = preg_match('#' . $term . '#mi', $item['uri']);
|
||||
if ($preg_match === 1) {
|
||||
if (preg_match('#' . $term . '#mi', $item['uri'])) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user