get_fields now filters out undefs in 3.x