fix for infinite scroll crashing, issue #187