fix sort to top/bottom