From 4c3b80fca915267336efd0defc0e6eb761da9924 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre=20Mazi=C3=A8re?= Date: Thu, 15 Sep 2016 11:13:18 +0200 Subject: [PATCH] [WordPressBridge] fix fatal errors MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Pierre Mazière --- bridges/WordPressBridge.php | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/bridges/WordPressBridge.php b/bridges/WordPressBridge.php index 114e651..0e9fd43 100644 --- a/bridges/WordPressBridge.php +++ b/bridges/WordPressBridge.php @@ -49,13 +49,18 @@ class WordPressBridge extends FeedExpander { return $item; } + public function getURI(){ + $url = $this->getInput('url'); + return $url; + } + public function collectData(){ - if(substr($this->getInput(url),0,srlen('http'))!=='http'){ + if(substr($this->getInput('url'),0,strlen('http'))!=='http'){ // just in case someone find a way to access local files by playing with the url - returnClientError('The url parameter must either refer to http or https protocol.'); + $this->returnClientError('The url parameter must either refer to http or https protocol.'); } - $this->collectExpandableDatas($this->getURI().'/feed/atom'); + $this->collectExpandableDatas($this->getURI().'/feed/atom/'); }