cleanup, rearrange things a bit
slight rearrangement
merge fix