Updated to non-deprecated methods