Fixed nil pointer dereference when body not successfully retrieved