[Misc] Replaced deprecated method calls