Passed
Push — master ( bc9194...646e1f )
by Gabriel
11:53
created
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.