put module def in the correct order