Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Useless call to array_map('trim', $args); #2750

Closed
johnbillion opened this issue Aug 1, 2017 · 0 comments
Closed

Useless call to array_map('trim', $args); #2750

johnbillion opened this issue Aug 1, 2017 · 0 comments

Comments

@johnbillion
Copy link
Sponsor Contributor

Q A
PHPUnit version 6.2.3
PHP version N/A
Installation Method N/A

The Getopt::getopt() method includes the following line of code, which appears to be useless. array_map() returns its result, rather than acting on the array passed in as a reference as some other array functions do.

\array_map('trim', $args);

Ref: https://github.com/sebastianbergmann/phpunit/blob/6.2.3/src/Util/Getopt.php#L37-L37

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant