Closed istrof closed 6 years ago
Thanks for your contribution @istrof!
Are you sure this works fine for return statements of the main function in code placed after the closure ? I think they would now be attached to the closure rather than the main function (instead of assigning the closure ones to the main function like before)
@stof, you're right, this case is not covered yet. Is there a way in PHPCS to detect closure/function we're currently in?
When closure is defined, this sniff should handle code inside closure.