Skip to content

Commit a52676b

Browse files
committed
[CodeQuality] Skip equal to identical on numeric string on UseIdenticalOverEqualWithSameTypeRector
1 parent 5f35406 commit a52676b

1 file changed

Lines changed: 20 additions & 0 deletions

File tree

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<?php
2+
3+
namespace Rector\Tests\CodeQuality\Rector\Equal\UseIdenticalOverEqualWithSameTypeRector\Fixture;
4+
5+
final class SkipIdenticalNumericString
6+
{
7+
public function equal()
8+
{
9+
if ($this->getValue() == '1') {
10+
return 'yes';
11+
}
12+
13+
return 'no';
14+
}
15+
16+
private function getValue(): string
17+
{
18+
return '1';
19+
}
20+
}

0 commit comments

Comments
 (0)