Fixing infinite scroll bugs.
Small images should not break the grid layout.