From 5432cabef5a79db8b8a1b913563bf1db5ffbb0bd Mon Sep 17 00:00:00 2001 From: logmanoriginal Date: Sat, 6 Aug 2016 17:55:29 +0200 Subject: [PATCH] bridges: Put name/uri directly in bridge metadata Some bridges used getName() and getURI() to put information into the metadatas. Instead the metadatas should be initialized with data and (not yet done) returned by default via getName() and getURI(). --- bridges/DilbertBridge.php | 8 ++++---- bridges/EstCeQuonMetEnProdBridge.php | 8 ++++---- bridges/FuturaSciencesBridge.php | 8 ++++---- bridges/LichessBridge.php | 10 +++++----- bridges/NakedSecurityBridge.php | 8 ++++---- bridges/NextgovBridge.php | 8 ++++---- bridges/ShanaprojectBridge.php | 8 ++++---- bridges/TheHackerNewsBridge.php | 8 ++++---- bridges/WeLiveSecurityBridge.php | 8 ++++---- bridges/ZDNetBridge.php | 8 ++++---- bridges/ZoneTelechargementBridge.php | 8 ++++---- 11 files changed, 45 insertions(+), 45 deletions(-) diff --git a/bridges/DilbertBridge.php b/bridges/DilbertBridge.php index f513ef9..c1a21ce 100644 --- a/bridges/DilbertBridge.php +++ b/bridges/DilbertBridge.php @@ -4,8 +4,8 @@ class DilbertBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'kranack'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Dilbert Daily Strip'; + $this->uri = 'http://dilbert.com'; $this->description = 'The Unofficial Dilbert Daily Comic Strip'; $this->update = "2016-08-06"; @@ -39,11 +39,11 @@ class DilbertBridge extends BridgeAbstract { } public function getName() { - return 'Dilbert Daily Strip'; + return $this->name; } public function getURI() { - return 'http://dilbert.com'; + return $this->uri; } public function getCacheDuration() { diff --git a/bridges/EstCeQuonMetEnProdBridge.php b/bridges/EstCeQuonMetEnProdBridge.php index b964ea4..7ca7ebb 100644 --- a/bridges/EstCeQuonMetEnProdBridge.php +++ b/bridges/EstCeQuonMetEnProdBridge.php @@ -3,8 +3,8 @@ class EstCeQuonMetEnProdBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Est-ce qu\'on met en prod aujourd\'hui ?'; + $this->uri = 'https://www.estcequonmetenprodaujourdhui.info/'; $this->description = 'Should we put a website in production today? (French)'; $this->update = "2016-08-06"; } @@ -38,11 +38,11 @@ class EstCeQuonMetEnProdBridge extends BridgeAbstract { } public function getName() { - return 'Est-ce qu\'on met en prod aujourd\'hui ?'; + return $this->name; } public function getURI() { - return 'https://www.estcequonmetenprodaujourdhui.info/'; + return $this->uri; } public function getCacheDuration() { diff --git a/bridges/FuturaSciencesBridge.php b/bridges/FuturaSciencesBridge.php index 0a37051..738b7f5 100644 --- a/bridges/FuturaSciencesBridge.php +++ b/bridges/FuturaSciencesBridge.php @@ -4,8 +4,8 @@ class FuturaSciencesBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Futura-Sciences Bridge'; + $this->uri = 'http://www.futura-sciences.com/'; $this->description = 'Returns the newest articles.'; $this->update = '2016-08-06'; @@ -220,10 +220,10 @@ class FuturaSciencesBridge extends BridgeAbstract { } public function getName() { - return 'Futura-Sciences Bridge'; + return $this->name; } public function getURI() { - return 'http://www.futura-sciences.com/'; + return $this->uri; } } diff --git a/bridges/LichessBridge.php b/bridges/LichessBridge.php index 88aab12..9ed1f75 100644 --- a/bridges/LichessBridge.php +++ b/bridges/LichessBridge.php @@ -5,10 +5,10 @@ class LichessBridge extends BridgeAbstract public function loadMetadatas() { $this->maintainer = 'AmauryCarrade'; - $this->name = $this->getName() . ' Bridge'; - $this->uri = $this->getURI(); + $this->name = 'Lichess Blog'; + $this->uri = 'http://lichess.org/blog'; $this->description = 'Returns the 5 newest posts from the Lichess blog (full text)'; - $this->update = "2016-03-22"; + $this->update = "2016-08-06"; } public function collectData(array $param) @@ -51,11 +51,11 @@ class LichessBridge extends BridgeAbstract public function getName() { - return 'Lichess Blog'; + return $this->name; } public function getURI() { - return 'http://lichess.org/blog'; + return $this->uri; } } diff --git a/bridges/NakedSecurityBridge.php b/bridges/NakedSecurityBridge.php index 355cbbc..99bfb1e 100644 --- a/bridges/NakedSecurityBridge.php +++ b/bridges/NakedSecurityBridge.php @@ -3,8 +3,8 @@ class NakedSecurityBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Naked Security'; + $this->uri = 'https://nakedsecurity.sophos.com/'; $this->description = 'Returns the newest articles.'; $this->update = '2016-08-06'; } @@ -71,10 +71,10 @@ class NakedSecurityBridge extends BridgeAbstract { } public function getName() { - return 'Naked Security'; + return $this->name; } public function getURI() { - return 'https://nakedsecurity.sophos.com/'; + return $this->uri; } } \ No newline at end of file diff --git a/bridges/NextgovBridge.php b/bridges/NextgovBridge.php index 7fdde73..1ef1938 100644 --- a/bridges/NextgovBridge.php +++ b/bridges/NextgovBridge.php @@ -4,8 +4,8 @@ class NextgovBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Nextgov Bridge'; + $this->uri = 'https://www.nextgov.com/'; $this->description = 'USA Federal technology news, best practices, and web 2.0 tools.'; $this->update = '2016-08-06'; @@ -97,10 +97,10 @@ class NextgovBridge extends BridgeAbstract { } public function getName() { - return 'Nextgov Bridge'; + return $this->name; } public function getURI() { - return 'https://www.nextgov.com/'; + return $this->uri; } } \ No newline at end of file diff --git a/bridges/ShanaprojectBridge.php b/bridges/ShanaprojectBridge.php index 59106a5..dd4e61d 100644 --- a/bridges/ShanaprojectBridge.php +++ b/bridges/ShanaprojectBridge.php @@ -2,8 +2,8 @@ class ShanaprojectBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'logmanoriginal'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Shanaproject Bridge'; + $this->uri = 'http://www.shanaproject.com'; $this->description = 'Returns a list of anime from the current Season Anime List'; $this->update = '2016-08-06'; } @@ -111,10 +111,10 @@ class ShanaprojectBridge extends BridgeAbstract { } public function getName(){ - return 'Shanaproject Bridge'; + return $this->name; } public function getURI(){ - return 'http://www.shanaproject.com'; + return $this->uri; } } diff --git a/bridges/TheHackerNewsBridge.php b/bridges/TheHackerNewsBridge.php index e09432c..5b06a6c 100644 --- a/bridges/TheHackerNewsBridge.php +++ b/bridges/TheHackerNewsBridge.php @@ -4,8 +4,8 @@ class TheHackerNewsBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'The Hacker News Bridge'; + $this->uri = 'https://thehackernews.com/'; $this->description = 'Cyber Security, Hacking, Technology News.'; $this->update = '2016-08-06'; @@ -77,10 +77,10 @@ class TheHackerNewsBridge extends BridgeAbstract { } public function getName() { - return 'The Hacker News Bridge'; + return $this->name; } public function getURI() { - return 'https://thehackernews.com/'; + return $this->uri; } } \ No newline at end of file diff --git a/bridges/WeLiveSecurityBridge.php b/bridges/WeLiveSecurityBridge.php index 97cd58a..1a2b73d 100644 --- a/bridges/WeLiveSecurityBridge.php +++ b/bridges/WeLiveSecurityBridge.php @@ -3,8 +3,8 @@ class WeLiveSecurityBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'We Live Security'; + $this->uri = 'http://www.welivesecurity.com/'; $this->description = 'Returns the newest articles.'; $this->update = '2016-08-06'; } @@ -62,10 +62,10 @@ class WeLiveSecurityBridge extends BridgeAbstract { } public function getName() { - return 'We Live Security'; + return $this-name; } public function getURI() { - return 'http://www.welivesecurity.com/'; + return $this->uri; } } \ No newline at end of file diff --git a/bridges/ZDNetBridge.php b/bridges/ZDNetBridge.php index 92ac649..6f066fb 100644 --- a/bridges/ZDNetBridge.php +++ b/bridges/ZDNetBridge.php @@ -4,8 +4,8 @@ class ZDNetBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'ZDNet Bridge'; + $this->uri = 'http://www.zdnet.com/'; $this->description = 'Technology News, Analysis, Comments and Product Reviews for IT Professionals.'; $this->update = '2016-08-06'; @@ -304,10 +304,10 @@ class ZDNetBridge extends BridgeAbstract { } public function getName() { - return 'ZDNet Bridge'; + return $this->name; } public function getURI() { - return 'http://www.zdnet.com/'; + return $this->uri; } } diff --git a/bridges/ZoneTelechargementBridge.php b/bridges/ZoneTelechargementBridge.php index d416dff..01da87d 100644 --- a/bridges/ZoneTelechargementBridge.php +++ b/bridges/ZoneTelechargementBridge.php @@ -4,8 +4,8 @@ class ZoneTelechargementBridge extends BridgeAbstract { public function loadMetadatas() { $this->maintainer = 'ORelio'; - $this->name = $this->getName(); - $this->uri = $this->getURI(); + $this->name = 'Zone Telechargement Bridge'; + $this->uri = 'https://www.zone-telechargement.com/'; $this->description = 'RSS proxy returning the newest releases.
You may specify a category found in RSS URLs, else main feed is selected.'; $this->update = "2016-08-06"; @@ -45,10 +45,10 @@ class ZoneTelechargementBridge extends BridgeAbstract { } public function getName() { - return 'Zone Telechargement Bridge'; + return $this->name; } public function getURI() { - return 'https://www.zone-telechargement.com/'; + return $this->uri; } }