]> git.wh0rd.org Git - tt-rss.git/commitdiff
check for headlines-spacer presence before querying infscroll on load
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Sat, 6 Apr 2013 09:01:34 +0000 (13:01 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Sat, 6 Apr 2013 09:01:34 +0000 (13:01 +0400)
js/viewfeed.js

index 77ec5ce069ed3b43c81d99b2f404223a696e9de9..108d27ea4dc53855fdf71dee3ef083cde1e30b10 100644 (file)
@@ -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();