MIR1001
DeprecatedMethodCall
A method marked @deprecated is called on an instance or via a static call.
Example
Section titled “Example”<?phpclass Api { /** @deprecated Use newMethod() instead */ public function oldMethod(): void {}
public function newMethod(): void {}}
$api = new Api();$api->oldMethod(); // deprecated callHow to fix
Section titled “How to fix”Switch to the recommended replacement method.
<?php$api = new Api();$api->newMethod();