when will `child` be null and what should be done then?