Fixed sorting issue on Safari and Chrome