Why not use my code snippet instead of a deprecated function then?