Completed
Pull Request — master (#87)
by
unknown
03:08
created
src/Rules/Xml/Sitemap/ValidRule.php 2 patches
Doc Comments   +1 added lines patch added patch discarded remove patch
@@ -37,6 +37,7 @@
 block discarded – undo
37 37
 
38 38
     /**
39 39
      * @param string
40
+     * @param \Psr\Http\Message\StreamInterface $body
40 41
      * @return array
41 42
      */
42 43
     private function getLocations($body) {
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
 
18 18
     private function getSchema()
19 19
     {
20
-        return __DIR__ . '/' . self::SCHEMA;
20
+        return __DIR__.'/'.self::SCHEMA;
21 21
     }
22 22
 
23 23
     private function validateBody($body, $filename)
@@ -28,13 +28,13 @@  discard block
 block discarded – undo
28 28
         $lastError = libxml_get_last_error();
29 29
         if ($lastError) {
30 30
             throw new ValidationFailedException(
31
-                'The given sitemap file (' . $filename . ') is not well formed (last error: ' . str_replace("\n", '', $lastError->message) . ').');
31
+                'The given sitemap file ('.$filename.') is not well formed (last error: '.str_replace("\n", '', $lastError->message).').');
32 32
         }
33 33
         $valid = @$dom->schemaValidate($this->getSchema());
34 34
         if (!$valid) {
35 35
             $lastError = libxml_get_last_error();
36 36
             throw new ValidationFailedException(
37
-                'The given sitemap file (' . $filename . ') did not validate against the sitemap schema (last error: ' . str_replace("\n", '', $lastError->message) . ').');
37
+                'The given sitemap file ('.$filename.') did not validate against the sitemap schema (last error: '.str_replace("\n", '', $lastError->message).').');
38 38
         }
39 39
     }
40 40
 
Please login to merge, or discard this patch.
src/Rules/Xml/XmlCheckRule.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -21,8 +21,8 @@
 block discarded – undo
21 21
         if (!$success) {
22 22
             $lastError = libxml_get_last_error();
23 23
 
24
-            throw new ValidationFailedException('The xml file ' . $response->getUri() . ' is not well formed (last error: ' .
25
-                str_replace("\n", '', $lastError->message) . ').');
24
+            throw new ValidationFailedException('The xml file '.$response->getUri().' is not well formed (last error: '.
25
+                str_replace("\n", '', $lastError->message).').');
26 26
         }
27 27
     }
28 28
 }
Please login to merge, or discard this patch.