Completed
Push — master ( db01b7...1c2473 )
by Tom
01:44
created
src/Formatter/Number.php 1 patch
Braces   +8 added lines, -3 removed lines patch added patch discarded remove patch
@@ -13,13 +13,18 @@
 block discarded – undo
13 13
 	}
14 14
 
15 15
 	public function decimal($num, $decimals) {
16
-		if (!is_numeric($num)) return $num;
16
+		if (!is_numeric($num)) {
17
+			return $num;
18
+		}
17 19
 		return number_format((float)$num, $decimals, $this->locale['decimal_separator'], $this->locale['thousands_separator']);
18 20
 	}
19 21
 
20 22
 	public function currency($num) {
21 23
 		$num = $this->decimal($num, $this->locale['currency_decimals']);
22
-		if ($this->locale['currency_position'] === 'before') return $this->locale['currency'] . $num;
23
-		else return $num . $this->locale['currency'];
24
+		if ($this->locale['currency_position'] === 'before') {
25
+			return $this->locale['currency'] . $num;
26
+		} else {
27
+			return $num . $this->locale['currency'];
28
+		}
24 29
 	}
25 30
 }
Please login to merge, or discard this patch.