check for headlines-spacer presence before querying infscroll on load

master
Andrew Dolgov 12 years ago
parent 2b28c8f2da
commit 86baa14aca

@ -212,8 +212,8 @@ function headlines_callback2(transport, offset, background, infscroll_req) {
// if we have some more space in the buffer, why not try to fill it
if (!_infscroll_disable && $("headlines-spacer").offsetTop <
$("headlines-frame").offsetHeight) {
if (!_infscroll_disable && $("headlines-spacer") &&
$("headlines-spacer").offsetTop < $("headlines-frame").offsetHeight) {
window.setTimeout(function() {
loadMoreHeadlines();

Loading…
Cancel
Save