fix getOrderByRest bug