Fix quality flaw on deprecated method call