Skip to content

Commit 66c0b00

Browse files
samsonasikTomasVotruba
authored andcommitted
add test for skip all strings in array_map()
1 parent 6f3e61d commit 66c0b00

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?php
2+
3+
namespace Rector\Tests\Php81\Rector\FuncCall\NullToStrictStringFuncCallArgRector\Fixture;
4+
5+
final class SkipArrayOfStringsOnArrayMap
6+
{
7+
public function foo(string $name)
8+
{
9+
$parts = explode('_', $name);
10+
return implode(
11+
'',
12+
array_map(
13+
fn ($part): string =>
14+
strtolower($part),
15+
$parts
16+
)
17+
);
18+
}
19+
}

0 commit comments

Comments
 (0)