WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit 70abe0d

Browse files
committed
Apply more CS rules
1 parent 6c7d205 commit 70abe0d

File tree

5 files changed

+6
-8
lines changed

5 files changed

+6
-8
lines changed

.php-cs-fixer.dist.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
'array_syntax' => false,
88
'concat_space' => false,
99
'blank_line_after_opening_tag' => false,
10-
'visibility_required' => false,
1110
'trailing_comma_in_multiline' => false,
1211
'method_argument_space' => false,
1312
'array_indentation' => false,
@@ -16,10 +15,8 @@
1615
'statement_indentation' => false,
1716
'binary_operator_spaces' => false,
1817
'single_blank_line_at_eof' => false,
19-
'elseif' => false,
2018
'control_structure_braces' => false,
2119
'control_structure_continuation_position' => false,
22-
'no_multiple_statements_per_line' => false,
2320
])
2421
->setFinder(
2522
PhpCsFixer\Finder::create()

Spreadsheet/Excel/Writer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public function send($filename)
8383
* @param integer $col Column for the cell to convert (0-indexed).
8484
* @return string The cell identifier in A1 format
8585
*/
86-
function rowcolToCell($row, $col)
86+
public function rowcolToCell($row, $col)
8787
{
8888
if ($col > 255) { //maximum column value exceeded
8989
return new PEAR_Error("Maximum column value exceeded: $col");

Spreadsheet/Excel/Writer/Workbook.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1414,7 +1414,7 @@ protected function _calculateSharedStringsSizes()
14141414
$align = 1;
14151415
}
14161416
// Split section without header => split on even boundary
1417-
else if ($split_string && $space_remaining % 2 == 1) {
1417+
elseif ($split_string && $space_remaining % 2 == 1) {
14181418
$space_remaining--;
14191419
$align = 1;
14201420
}
@@ -1587,7 +1587,7 @@ protected function _storeSharedStringsTable()
15871587
$align = 1;
15881588
}
15891589
// Split section without header => split on even boundary
1590-
else if ($split_string && $space_remaining % 2 == 1) {
1590+
elseif ($split_string && $space_remaining % 2 == 1) {
15911591
$space_remaining--;
15921592
$align = 1;
15931593
}

Spreadsheet/Excel/Writer/Worksheet.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -878,7 +878,8 @@ public function setColumn($firstcol, $lastcol, $width, $format = null, $hidden =
878878
// look for any ranges this might overlap and remove, size or split where necessary
879879
foreach ($this->_colinfo as $key => $colinfo)
880880
{
881-
$existing_start = $colinfo[0]; $existing_end = $colinfo[1];
881+
$existing_start = $colinfo[0];
882+
$existing_end = $colinfo[1];
882883
// if the new range starts within another range
883884
if ($firstcol > $existing_start && $firstcol < $existing_end)
884885
{ // trim the existing range to the beginning of the new range

test/Test/Spreadsheet/Excel/WriterTestCase.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*/
77
class Test_Spreadsheet_Excel_WriterTestCase extends \LegacyPHPUnit\TestCase
88
{
9-
const FIXTURES_PATH = 'test/fixture/';
9+
public const FIXTURES_PATH = 'test/fixture/';
1010

1111
/**
1212
* @param string $filename

0 commit comments

Comments
 (0)