change document.body.scrollTop to .scrollTop()

This commit is contained in:
Baris Soner Usakli
2013-08-21 13:17:16 -04:00
parent e2ffac74bc
commit ac56f3a30a
6 changed files with 6 additions and 6 deletions

View File

@@ -206,7 +206,7 @@
$(window).off('scroll').on('scroll', function() {
var bottom = (document.body.offsetHeight - $(window).height()) * 0.9;
if ((document.documentElement.scrollTop || document.body.scrollTop) > bottom && !app.infiniteLoaderActive && $('#post-container').children().length) {
if ($(window).scrollTop() > bottom && !app.infiniteLoaderActive && $('#post-container').children().length) {
app.loadMorePosts(tid);
}
});