mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-08 15:05:46 +01:00
dont infinite load if there are no topics loaded
This commit is contained in:
@@ -205,7 +205,7 @@
|
|||||||
var windowHeight = document.body.offsetHeight - $(window).height(),
|
var windowHeight = document.body.offsetHeight - $(window).height(),
|
||||||
half = windowHeight / 2;
|
half = windowHeight / 2;
|
||||||
|
|
||||||
if (document.body.scrollTop > half && !app.infiniteLoaderActive) {
|
if (document.body.scrollTop > half && !app.infiniteLoaderActive && $('#post-container').children().length) {
|
||||||
app.loadMorePosts(tid);
|
app.loadMorePosts(tid);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user