optimizing infinite scroll querying