ordering by date fix