From: Andrew Dolgov Date: Sat, 6 Apr 2013 09:01:34 +0000 (+0400) Subject: check for headlines-spacer presence before querying infscroll on load X-Git-Tag: 1.7.9~55 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=86baa14acaf932222952e0c7d4fbd123cb257474;p=tt-rss.git check for headlines-spacer presence before querying infscroll on load --- diff --git a/js/viewfeed.js b/js/viewfeed.js index 77ec5ce0..108d27ea 100644 --- a/js/viewfeed.js +++ b/js/viewfeed.js @@ -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();