tidying the looks of this code