How to deal with “method not found in class” warning for magically implemented methods?

后端 未结 4 1783
长发绾君心
长发绾君心 2020-12-05 09:08

I am sitting on a large codebase that contains several classes that expose functionality through magically implemented methods (using __call and __callSta

4条回答
  •  鱼传尺愫
    2020-12-05 09:53

    Well, you can go to the preference menu, under Inspections, go to Undefined -> Undefined Method and check Downgrade severity if __magic methods are present.

    That would make the flag less severe, (instead of Warning, as Info), which would still give you a green light on your document check.

    There's nothing else I'm aware of aside from having @property or @method PHPDoc notations on the target class for every method that's likely to be used.

    enter image description here

提交回复
热议问题