0
0
mirror of https://github.com/RSS-Bridge/rss-bridge.git synced 2025-08-28 14:25:41 +00:00

[CybernewsBridge] fix lint

This commit is contained in:
tillcash 2025-08-10 15:54:15 +05:30 committed by GitHub
parent d0b1789560
commit daddb8b40f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,6 +1,7 @@
<?php
class CybernewsBridge extends BridgeAbstract {
class CybernewsBridge extends BridgeAbstract
{
const NAME = 'Cybernews';
const URI = 'https://cybernews.com';
const DESCRIPTION = 'Fetches the latest news from Cybernews';
@ -8,7 +9,8 @@ class CybernewsBridge extends BridgeAbstract {
const CACHE_TIMEOUT = 3600; // 1 hour
const MAX_ARTICLES = 5;
public function collectData() {
public function collectData()
{
$sitemapXml = getContents(self::URI . '/news-sitemap.xml');
if (!$sitemapXml) {
throwServerException('Could not retrieve Cybernews sitemap');
@ -65,7 +67,8 @@ class CybernewsBridge extends BridgeAbstract {
}
}
private function fetchFullArticle($url) {
private function fetchFullArticle($url)
{
$html = getSimpleHTMLDOMCached($url);
if (!$html) {
return 'Failed to fetch article content';