Passed
Pull Request — master (#3793)
by Adrien
14:51
created
Category
src/PhpSpreadsheet/Writer/Xls/Worksheet.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2116,7 +2116,7 @@  discard block
 block discarded – undo
2116 2116
      * @param float $scale_x The horizontal scale
2117 2117
      * @param float $scale_y The vertical scale
2118 2118
      */
2119
-    public function insertBitmap(int $row, int $col, GdImage|string $bitmap, int $x = 0, int $y = 0, float $scale_x = 1, float $scale_y = 1): void
2119
+    public function insertBitmap(int $row, int $col, GdImage | string $bitmap, int $x = 0, int $y = 0, float $scale_x = 1, float $scale_y = 1): void
2120 2120
     {
2121 2121
         $bitmap_array = $bitmap instanceof GdImage
2122 2122
             ? $this->processBitmapGd($bitmap)
@@ -2258,7 +2258,7 @@  discard block
 block discarded – undo
2258 2258
      * @param int $rwB Row containing bottom right corner of object
2259 2259
      * @param int $dyB Distance from bottom of cell
2260 2260
      */
2261
-    private function writeObjPicture(int $colL, int $dxL, int $rwT, int|float $dyT, int $colR, int $dxR, int $rwB, int $dyB): void
2261
+    private function writeObjPicture(int $colL, int $dxL, int $rwT, int | float $dyT, int $colR, int $dxR, int $rwB, int $dyB): void
2262 2262
     {
2263 2263
         $record = 0x005D; // Record identifier
2264 2264
         $length = 0x003C; // Bytes to follow
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Writer/Html.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1297,7 +1297,7 @@  discard block
 block discarded – undo
1297 1297
         }
1298 1298
     }
1299 1299
 
1300
-    private function generateRowCellData(Worksheet $worksheet, null|Cell|string $cell, array|string &$cssClass): string
1300
+    private function generateRowCellData(Worksheet $worksheet, null | Cell | string $cell, array | string &$cssClass): string
1301 1301
     {
1302 1302
         $cellData = ' ';
1303 1303
         if ($cell instanceof Cell) {
@@ -1367,7 +1367,7 @@  discard block
 block discarded – undo
1367 1367
         string $cellData,
1368 1368
         int $colSpan,
1369 1369
         int $rowSpan,
1370
-        array|string $cssClass,
1370
+        array | string $cssClass,
1371 1371
         int $colNum,
1372 1372
         int $sheetIndex,
1373 1373
         int $row
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Helper/Dimension.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@
 block discarded – undo
48 48
      *                If this is a height, then size is measured in pixels ()
49 49
      *                   or in points () if $unit is null.
50 50
      */
51
-    protected float|int $size;
51
+    protected float | int $size;
52 52
 
53 53
     protected ?string $unit = null;
54 54
 
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Document/Properties.php 1 patch
Spacing   +33 added lines, -33 removed lines patch added patch discarded remove patch
@@ -36,12 +36,12 @@  discard block
 block discarded – undo
36 36
     /**
37 37
      * Created.
38 38
      */
39
-    private float|int $created;
39
+    private float | int $created;
40 40
 
41 41
     /**
42 42
      * Modified.
43 43
      */
44
-    private float|int $modified;
44
+    private float | int $modified;
45 45
 
46 46
     /**
47 47
      * Title.
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
         return $this;
141 141
     }
142 142
 
143
-    private static function intOrFloatTimestamp(null|float|int|string $timestamp): float|int
143
+    private static function intOrFloatTimestamp(null | float | int | string $timestamp): float | int
144 144
     {
145 145
         if ($timestamp === null) {
146 146
             $timestamp = (float) (new DateTime())->format('U');
@@ -161,7 +161,7 @@  discard block
 block discarded – undo
161 161
     /**
162 162
      * Get Created.
163 163
      */
164
-    public function getCreated(): float|int
164
+    public function getCreated(): float | int
165 165
     {
166 166
         return $this->created;
167 167
     }
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
      *
172 172
      * @return $this
173 173
      */
174
-    public function setCreated(null|float|int|string $timestamp): self
174
+    public function setCreated(null | float | int | string $timestamp): self
175 175
     {
176 176
         $this->created = self::intOrFloatTimestamp($timestamp);
177 177
 
@@ -181,7 +181,7 @@  discard block
 block discarded – undo
181 181
     /**
182 182
      * Get Modified.
183 183
      */
184
-    public function getModified(): float|int
184
+    public function getModified(): float | int
185 185
     {
186 186
         return $this->modified;
187 187
     }
@@ -191,7 +191,7 @@  discard block
 block discarded – undo
191 191
      *
192 192
      * @return $this
193 193
      */
194
-    public function setModified(null|float|int|string $timestamp): self
194
+    public function setModified(null | float | int | string $timestamp): self
195 195
     {
196 196
         $this->modified = self::intOrFloatTimestamp($timestamp);
197 197
 
@@ -415,32 +415,32 @@  discard block
 block discarded – undo
415 415
     }
416 416
 
417 417
     private const PROPERTY_TYPE_ARRAY = [
418
-        'i' => self::PROPERTY_TYPE_INTEGER,      //    Integer
419
-        'i1' => self::PROPERTY_TYPE_INTEGER,     //    1-Byte Signed Integer
420
-        'i2' => self::PROPERTY_TYPE_INTEGER,     //    2-Byte Signed Integer
421
-        'i4' => self::PROPERTY_TYPE_INTEGER,     //    4-Byte Signed Integer
422
-        'i8' => self::PROPERTY_TYPE_INTEGER,     //    8-Byte Signed Integer
423
-        'int' => self::PROPERTY_TYPE_INTEGER,    //    Integer
424
-        'ui1' => self::PROPERTY_TYPE_INTEGER,    //    1-Byte Unsigned Integer
425
-        'ui2' => self::PROPERTY_TYPE_INTEGER,    //    2-Byte Unsigned Integer
426
-        'ui4' => self::PROPERTY_TYPE_INTEGER,    //    4-Byte Unsigned Integer
427
-        'ui8' => self::PROPERTY_TYPE_INTEGER,    //    8-Byte Unsigned Integer
428
-        'uint' => self::PROPERTY_TYPE_INTEGER,   //    Unsigned Integer
429
-        'f' => self::PROPERTY_TYPE_FLOAT,        //    Real Number
430
-        'r4' => self::PROPERTY_TYPE_FLOAT,       //    4-Byte Real Number
431
-        'r8' => self::PROPERTY_TYPE_FLOAT,       //    8-Byte Real Number
432
-        'decimal' => self::PROPERTY_TYPE_FLOAT,  //    Decimal
433
-        's' => self::PROPERTY_TYPE_STRING,       //    String
434
-        'empty' => self::PROPERTY_TYPE_STRING,   //    Empty
435
-        'null' => self::PROPERTY_TYPE_STRING,    //    Null
436
-        'lpstr' => self::PROPERTY_TYPE_STRING,   //    LPSTR
437
-        'lpwstr' => self::PROPERTY_TYPE_STRING,  //    LPWSTR
438
-        'bstr' => self::PROPERTY_TYPE_STRING,    //    Basic String
439
-        'd' => self::PROPERTY_TYPE_DATE,         //    Date and Time
440
-        'date' => self::PROPERTY_TYPE_DATE,      //    Date and Time
441
-        'filetime' => self::PROPERTY_TYPE_DATE,  //    File Time
442
-        'b' => self::PROPERTY_TYPE_BOOLEAN,      //    Boolean
443
-        'bool' => self::PROPERTY_TYPE_BOOLEAN,   //    Boolean
418
+        'i' => self::PROPERTY_TYPE_INTEGER, //    Integer
419
+        'i1' => self::PROPERTY_TYPE_INTEGER, //    1-Byte Signed Integer
420
+        'i2' => self::PROPERTY_TYPE_INTEGER, //    2-Byte Signed Integer
421
+        'i4' => self::PROPERTY_TYPE_INTEGER, //    4-Byte Signed Integer
422
+        'i8' => self::PROPERTY_TYPE_INTEGER, //    8-Byte Signed Integer
423
+        'int' => self::PROPERTY_TYPE_INTEGER, //    Integer
424
+        'ui1' => self::PROPERTY_TYPE_INTEGER, //    1-Byte Unsigned Integer
425
+        'ui2' => self::PROPERTY_TYPE_INTEGER, //    2-Byte Unsigned Integer
426
+        'ui4' => self::PROPERTY_TYPE_INTEGER, //    4-Byte Unsigned Integer
427
+        'ui8' => self::PROPERTY_TYPE_INTEGER, //    8-Byte Unsigned Integer
428
+        'uint' => self::PROPERTY_TYPE_INTEGER, //    Unsigned Integer
429
+        'f' => self::PROPERTY_TYPE_FLOAT, //    Real Number
430
+        'r4' => self::PROPERTY_TYPE_FLOAT, //    4-Byte Real Number
431
+        'r8' => self::PROPERTY_TYPE_FLOAT, //    8-Byte Real Number
432
+        'decimal' => self::PROPERTY_TYPE_FLOAT, //    Decimal
433
+        's' => self::PROPERTY_TYPE_STRING, //    String
434
+        'empty' => self::PROPERTY_TYPE_STRING, //    Empty
435
+        'null' => self::PROPERTY_TYPE_STRING, //    Null
436
+        'lpstr' => self::PROPERTY_TYPE_STRING, //    LPSTR
437
+        'lpwstr' => self::PROPERTY_TYPE_STRING, //    LPWSTR
438
+        'bstr' => self::PROPERTY_TYPE_STRING, //    Basic String
439
+        'd' => self::PROPERTY_TYPE_DATE, //    Date and Time
440
+        'date' => self::PROPERTY_TYPE_DATE, //    Date and Time
441
+        'filetime' => self::PROPERTY_TYPE_DATE, //    File Time
442
+        'b' => self::PROPERTY_TYPE_BOOLEAN, //    Boolean
443
+        'bool' => self::PROPERTY_TYPE_BOOLEAN, //    Boolean
444 444
     ];
445 445
 
446 446
     private const SPECIAL_TYPES = [
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Worksheet/Worksheet.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -3100,7 +3100,7 @@
 block discarded – undo
3100 3100
      *
3101 3101
      * @return ($range is non-empty-string ? ($returnRange is true ? array{0: string, 1: string} : string) : ($returnRange is true ? array{0: null, 1: null} : null))
3102 3102
      */
3103
-    public static function extractSheetTitle(?string $range, bool $returnRange = false): array|null|string
3103
+    public static function extractSheetTitle(?string $range, bool $returnRange = false): array | null | string
3104 3104
     {
3105 3105
         if (empty($range)) {
3106 3106
             return $returnRange ? [null, null] : null;
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Worksheet/AutoFilter/Column.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -252,7 +252,7 @@
 block discarded – undo
252 252
      *
253 253
      * @param string $name Attribute Name
254 254
      */
255
-    public function getAttribute(string $name): null|int|string
255
+    public function getAttribute(string $name): null | int | string
256 256
     {
257 257
         if (isset($this->attributes[$name])) {
258 258
             return $this->attributes[$name];
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Worksheet/AutoFilter.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
     /**
72 72
      * Get AutoFilter Parent Worksheet.
73 73
      */
74
-    public function getParent(): null|Worksheet
74
+    public function getParent(): null | Worksheet
75 75
     {
76 76
         return $this->workSheet;
77 77
     }
@@ -233,7 +233,7 @@  discard block
 block discarded – undo
233 233
      *
234 234
      * @return $this
235 235
      */
236
-    public function setColumn(AutoFilter\Column|string $columnObjectOrString): static
236
+    public function setColumn(AutoFilter\Column | string $columnObjectOrString): static
237 237
     {
238 238
         $this->evaluated = false;
239 239
         if ((is_string($columnObjectOrString)) && (!empty($columnObjectOrString))) {
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Worksheet/Table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -437,7 +437,7 @@
 block discarded – undo
437 437
      * @param string|Table\Column $columnObjectOrString
438 438
      *            A simple string containing a Column ID like 'A' is permitted
439 439
      */
440
-    public function setColumn(string|Table\Column $columnObjectOrString): self
440
+    public function setColumn(string | Table\Column $columnObjectOrString): self
441 441
     {
442 442
         if ((is_string($columnObjectOrString)) && (!empty($columnObjectOrString))) {
443 443
             $column = $columnObjectOrString;
Please login to merge, or discard this patch.
src/PhpSpreadsheet/Cell/DataType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
      *
54 54
      * @return RichText|string Sanitized value
55 55
      */
56
-    public static function checkString(null|RichText|string $textValue): RichText|string
56
+    public static function checkString(null | RichText | string $textValue): RichText | string
57 57
     {
58 58
         if ($textValue instanceof RichText) {
59 59
             // TODO: Sanitize Rich-Text string (max. character count is 32,767)
Please login to merge, or discard this patch.