Fix sort order, closes #12