You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Generic/UselessOverridingMethod: bail if not checking a class method
The UselessOverridingMethod is triggered when the T_FUNCTION token is
found. This token is used for regular functions and also methods.
The sniff should run only for class and trait methods (including abstract and
anonymous classes). Those are the only methods that can have a parent.
So this commit changes the sniff to bail early when dealing with a
regular function, nested function or enum method.
0 commit comments