Orders refactor