Fix bug with order