Passed
Push — master ( 04aa33...03340d )
by Andreas
12:21
created
lib/midcom/helper/imagefilter.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -323,7 +323,7 @@  discard block
 block discarded – undo
323 323
         $tmpfile = null;
324 324
         $imagesize = getimagesize($this->_filename);
325 325
 
326
-        if (   $imagesize[2] == IMAGETYPE_JPEG
326
+        if ($imagesize[2] == IMAGETYPE_JPEG
327 327
             && $this->_jpegtran_available()) {
328 328
             /* jpegtran */
329 329
             $operations = [
@@ -390,7 +390,7 @@  discard block
 block discarded – undo
390 390
         $imagesize = getimagesize($this->_filename);
391 391
 
392 392
         // Try lossless jpegtran rotation if possible
393
-        if (   $imagesize[2] == IMAGETYPE_JPEG
393
+        if ($imagesize[2] == IMAGETYPE_JPEG
394 394
             && ($rotate % 90 == 0)
395 395
             && $this->_jpegtran_available()) {
396 396
             $tmpfile = $this->_get_tempfile();
@@ -502,7 +502,7 @@  discard block
 block discarded – undo
502 502
      */
503 503
     public function fill(?int $x = null, ?int $y = null, ?string $color = null, string $gravity = 'center')
504 504
     {
505
-        if (   empty($x)
505
+        if (empty($x)
506 506
             || empty($y)
507 507
             || empty($color)) {
508 508
             //This is a bit silly, but here for backwards compatibility...
Please login to merge, or discard this patch.
lib/midcom/services/i18n/formatter.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
         $this->language = $language;
24 24
     }
25 25
 
26
-    public function number(int|float $value, int $precision = 2)
26
+    public function number(int | float $value, int $precision = 2)
27 27
     {
28 28
         // The fallback implementation in Intl only supports DECIMAL, so we hardcode the style here..
29 29
         $formatter = new NumberFormatter($this->get_locale(), NumberFormatter::DECIMAL);
@@ -31,24 +31,24 @@  discard block
 block discarded – undo
31 31
         return $formatter->format($value);
32 32
     }
33 33
 
34
-    public function date(int|string|DateTimeInterface $value = null, int|string $dateformat = 'medium')
34
+    public function date(int | string | DateTimeInterface $value = null, int | string $dateformat = 'medium')
35 35
     {
36 36
         return $this->datetime($value, $dateformat, IntlDateFormatter::NONE);
37 37
     }
38 38
 
39
-    public function time(int|string|DateTimeInterface $value = null, int|string $timeformat = 'short')
39
+    public function time(int | string | DateTimeInterface $value = null, int | string $timeformat = 'short')
40 40
     {
41 41
         return $this->datetime($value, IntlDateFormatter::NONE, $timeformat);
42 42
     }
43 43
 
44
-    public function datetime(int|string|DateTimeInterface $value = null, int|string $dateformat = 'medium', int|string $timeformat = 'short')
44
+    public function datetime(int | string | DateTimeInterface $value = null, int | string $dateformat = 'medium', int | string $timeformat = 'short')
45 45
     {
46 46
         $value ??= time();
47 47
         $formatter = new IntlDateFormatter($this->get_locale(), $this->constant($dateformat), $this->constant($timeformat));
48 48
         return $formatter->format($value);
49 49
     }
50 50
 
51
-    public function customdate(int|string|DateTimeInterface $value, string $pattern)
51
+    public function customdate(int | string | DateTimeInterface $value, string $pattern)
52 52
     {
53 53
         $formatter = new IntlDateFormatter($this->get_locale(), IntlDateFormatter::FULL, IntlDateFormatter::FULL);
54 54
         $formatter->setPattern($pattern);
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
         return $ranger->format($start, $end);
71 71
     }
72 72
 
73
-    private function constant(int|string $input) : int
73
+    private function constant(int | string $input) : int
74 74
     {
75 75
         if (is_int($input)) {
76 76
             return $input;
Please login to merge, or discard this patch.