Step A in removing depreciated methods and magic value usage