removing many vars, nulls, and returns