Skip to content

Commit d7f6630

Browse files
committed
clean up result variable
1 parent e773020 commit d7f6630

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

rules-tests/DowngradePhp85/Rector/StmtsAwareInterface/DowngradePipeOperatorRectorTest/Fixture/complex_pipe_chain.php.inc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ declare(strict_types=1);
1919
namespace Rector\Tests\DowngradePhp85\Rector\StmtsAwareInterface\DowngradePipeOperatorRector\Fixture;
2020

2121
$data = " Hello, World! ";
22-
$result1 = trim($data);
23-
$result2 = strtoupper($result1);
24-
$result3 = (fn($str) => str_replace('WORLD', 'PHP', $str))($result2);
25-
$processed = addslashes($result3);
22+
$result = trim($data);
23+
$result = strtoupper($result);
24+
$result = (fn($str) => str_replace('WORLD', 'PHP', $str))($result);
25+
$processed = addslashes($result);
2626
?>

rules-tests/DowngradePhp85/Rector/StmtsAwareInterface/DowngradePipeOperatorRectorTest/Fixture/multiple_pipes.php.inc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ declare(strict_types=1);
1919
namespace Rector\Tests\DowngradePhp85\Rector\StmtsAwareInterface\DowngradePipeOperatorRector\Fixture;
2020

2121
$value = "hello world";
22-
$result1 = function3($value);
23-
$result2 = function2($result1);
24-
$result = function1($result2);
22+
$result = function3($value);
23+
$result = function2($result);
24+
$result = function1($result);
2525

2626
?>

rules-tests/DowngradePhp85/Rector/StmtsAwareInterface/DowngradePipeOperatorRectorTest/Fixture/pipe_in_assignment.php.inc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ declare(strict_types=1);
1616
namespace Rector\Tests\DowngradePhp85\Rector\StmtsAwareInterface\DowngradePipeOperatorRector\Fixture;
1717

1818
$value = " test ";
19-
$result1 = trim($value);
20-
$result = strtoupper($result1);
19+
$result = trim($value);
20+
$result = strtoupper($result);
2121

2222
?>

rules-tests/DowngradePhp85/Rector/StmtsAwareInterface/DowngradePipeOperatorRectorTest/Fixture/pipe_with_closure.php.inc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ declare(strict_types=1);
1414

1515
namespace Rector\Tests\DowngradePhp85\Rector\StmtsAwareInterface\DowngradePipeOperatorRector\Fixture;
1616

17-
$result1 = (fn($x) => strtoupper($x))("hello");
18-
$result = (fn($y) => $y . '!')($result1);
17+
$result = (fn($x) => strtoupper($x))("hello");
18+
$result = (fn($y) => $y . '!')($result);
1919

2020
?>

0 commit comments

Comments
 (0)