Passed
Push — master ( bc9194...646e1f )
by Gabriel
11:53
created
src/Models/Currencies/CurrencyTrait.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -29,20 +29,20 @@
 block discarded – undo
29 29
         $amount = strpos($amount, '.') !== false ? $amount : $amount . '.0';
30 30
 
31 31
         list($integerValue, $decimalValue) = explode('.', $amount);
32
-        $intHTML = '<span class="money-int">'.number_format($integerValue).'</span>';
32
+        $intHTML = '<span class="money-int">' . number_format($integerValue) . '</span>';
33 33
 
34 34
         $decimalValue = str_pad($decimalValue, 2, '0', STR_PAD_LEFT);
35
-        $decimalHTML = '<sup class="money-decimal">.'.$decimalValue.'</sup>';
35
+        $decimalHTML = '<sup class="money-decimal">.' . $decimalValue . '</sup>';
36 36
 
37
-        $return = $intHTML.$decimalHTML;
37
+        $return = $intHTML . $decimalHTML;
38 38
 
39
-        $symbolHTML = '<span class="money-currency">'.$this->symbol.'</span>';
39
+        $symbolHTML = '<span class="money-currency">' . $this->symbol . '</span>';
40 40
         if ($this->position == 'before') {
41
-            $return = $symbolHTML.' '.$amount;
41
+            $return = $symbolHTML . ' ' . $amount;
42 42
         } else {
43
-            $return .= ' '.$symbolHTML;
43
+            $return .= ' ' . $symbolHTML;
44 44
         }
45 45
 
46
-        return '<span class="price" content="'.$amount.'">'.$return.'</span>';
46
+        return '<span class="price" content="' . $amount . '">' . $return . '</span>';
47 47
     }
48 48
 }
Please login to merge, or discard this patch.
src/functions/general.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@  discard block
 block discarded – undo
18 18
 if (!function_exists('money_format')) {
19 19
     function money_format($format, $number)
20 20
     {
21
-        $regex = '/%((?:[\^!\-]|\+|\(|\=.)*)([0-9]+)?'.
21
+        $regex = '/%((?:[\^!\-]|\+|\(|\=.)*)([0-9]+)?' .
22 22
             '(?:#([0-9]+))?(?:\.([0-9]+))?([in%])/';
23 23
         if (setlocale(LC_MONETARY, 0) == 'C') {
24 24
             setlocale(LC_MONETARY, '');
@@ -36,9 +36,9 @@  discard block
 block discarded – undo
36 36
                 'nosimbol' => preg_match('/\!/', $fmatch[1]) > 0,
37 37
                 'isleft' => preg_match('/\-/', $fmatch[1]) > 0,
38 38
             ];
39
-            $width = trim($fmatch[2]) ? (int)$fmatch[2] : 0;
40
-            $left = trim($fmatch[3]) ? (int)$fmatch[3] : 0;
41
-            $right = trim($fmatch[4]) ? (int)$fmatch[4] : $locale['int_frac_digits'];
39
+            $width = trim($fmatch[2]) ? (int) $fmatch[2] : 0;
40
+            $left = trim($fmatch[3]) ? (int) $fmatch[3] : 0;
41
+            $right = trim($fmatch[4]) ? (int) $fmatch[4] : $locale['int_frac_digits'];
42 42
             $conversion = $fmatch[5];
43 43
 
44 44
             $positive = true;
@@ -71,8 +71,8 @@  discard block
 block discarded – undo
71 71
                     break;
72 72
             }
73 73
             if (!$flags['nosimbol']) {
74
-                $currency = $cprefix.
75
-                    ($conversion == 'i' ? $locale['int_curr_symbol'] : $locale['currency_symbol']).
74
+                $currency = $cprefix .
75
+                    ($conversion == 'i' ? $locale['int_curr_symbol'] : $locale['currency_symbol']) .
76 76
                     $csuffix;
77 77
             } else {
78 78
                 $currency = '';
@@ -85,13 +85,13 @@  discard block
 block discarded – undo
85 85
 
86 86
             $n = strlen($prefix) + strlen($currency) + strlen($value[0]);
87 87
             if ($left > 0 && $left > $n) {
88
-                $value[0] = str_repeat($flags['fillchar'], $left - $n).$value[0];
88
+                $value[0] = str_repeat($flags['fillchar'], $left - $n) . $value[0];
89 89
             }
90 90
             $value = implode($locale['mon_decimal_point'], $value);
91 91
             if ($locale["{$letter}_cs_precedes"]) {
92
-                $value = $prefix.$currency.$space.$value.$suffix;
92
+                $value = $prefix . $currency . $space . $value . $suffix;
93 93
             } else {
94
-                $value = $prefix.$value.$space.$currency.$suffix;
94
+                $value = $prefix . $value . $space . $currency . $suffix;
95 95
             }
96 96
             if ($width > 0) {
97 97
                 $value = str_pad($value, $width, $flags['fillchar'], $flags['isleft'] ?
Please login to merge, or discard this patch.