Test Failed
Push — master ( fc4f20...ea5a85 )
by stéphane
13:54
created
sources/DumperHandlers.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,8 +22,12 @@
 block discarded – undo
22 22
 
23 23
     public function dumpScalar($dataType):string
24 24
     {
25
-        if ($dataType === \INF) return '.inf';
26
-        if ($dataType === -\INF) return '-.inf';
25
+        if ($dataType === \INF) {
26
+            return '.inf';
27
+        }
28
+        if ($dataType === -\INF) {
29
+            return '-.inf';
30
+        }
27 31
         $precision = "%.".$this->dumper->floatPrecision."F";
28 32
         switch (gettype($dataType)) {
29 33
             case 'boolean': return $dataType ? 'true' : 'false';
Please login to merge, or discard this patch.
sources/Dumper.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,9 @@
 block discarded – undo
48 48
      */
49 49
     public function toString($dataType, int $options = null):string
50 50
     {
51
-        if (empty($dataType)) throw new \Exception(self::class.": No content to convert to Yaml");
51
+        if (empty($dataType)) {
52
+            throw new \Exception(self::class.": No content to convert to Yaml");
53
+        }
52 54
         if (is_scalar($dataType)) {
53 55
             return "--- ".$this->handler->dumpScalar($dataType). self::LINEFEED ;
54 56
         }
Please login to merge, or discard this patch.