some little rearrangements. tests still passing