From b765ca3ae3d5590fddd4019829bbb9488d7eb7a5 Mon Sep 17 00:00:00 2001 From: Andres Rey Date: Sat, 2 Dec 2017 21:10:16 +0000 Subject: Apply fixes from StyleCI --- src/Nodes/NodeUtility.php | 2 +- src/ParseException.php | 2 -- src/Readability.php | 6 ++++-- test/ReadabilityTest.php | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/Nodes/NodeUtility.php b/src/Nodes/NodeUtility.php index 800e530..0e1072f 100644 --- a/src/Nodes/NodeUtility.php +++ b/src/Nodes/NodeUtility.php @@ -3,8 +3,8 @@ namespace andreskrey\Readability\Nodes; use andreskrey\Readability\Nodes\DOM\DOMDocument; -use andreskrey\Readability\Nodes\DOM\DOMNode; use andreskrey\Readability\Nodes\DOM\DOMElement; +use andreskrey\Readability\Nodes\DOM\DOMNode; /** * Class NodeUtility. diff --git a/src/ParseException.php b/src/ParseException.php index 335851f..646c04a 100644 --- a/src/ParseException.php +++ b/src/ParseException.php @@ -2,8 +2,6 @@ namespace andreskrey\Readability; - class ParseException extends \Exception { - } diff --git a/src/Readability.php b/src/Readability.php index 90d18d7..4dcde3c 100644 --- a/src/Readability.php +++ b/src/Readability.php @@ -108,6 +108,7 @@ class Readability * Main parse function. * * @param $html + * * @throws ParseException * * @return array|bool @@ -444,7 +445,7 @@ class Readability } /** - * Convert URI to an absolute URI + * Convert URI to an absolute URI. * * @param $uri string URI to convert * @@ -484,7 +485,7 @@ class Readability } /** - * Returns full path info of an URL + * Returns full path info of an URL. * * @param string $url * @@ -1371,6 +1372,7 @@ class Readability /** * @param DOMDocument $article + * * @return DOMDocument */ public function postProcessContent(DOMDocument $article) diff --git a/test/ReadabilityTest.php b/test/ReadabilityTest.php index c505ae6..e074983 100644 --- a/test/ReadabilityTest.php +++ b/test/ReadabilityTest.php @@ -19,7 +19,7 @@ class ReadabilityTest extends \PHPUnit_Framework_TestCase 'ArticleByLine' => true ]; - if($config === null || $expectedMetadata === null){ + if ($config === null || $expectedMetadata === null) { $this->markTestSkipped('Wrong test configuration'); } @@ -39,7 +39,7 @@ class ReadabilityTest extends \PHPUnit_Framework_TestCase $this->assertEquals($expectedResult, $readability->getContent()); - foreach($expectedMetadata as $key => $metadata){ + foreach ($expectedMetadata as $key => $metadata) { $function = 'get' . $key; $this->assertEquals($metadata, $readability->$function()); } -- cgit v1.2.3