From 86565e2462c5ec6cec49c47170a279419e8fba73 Mon Sep 17 00:00:00 2001 From: perry Date: Fri, 8 May 2015 10:56:43 -0500 Subject: [PATCH] fix(infiniteScroll): prevent error on infinite scroll complete with native scrolling Closes #3682 --- js/angular/controller/infiniteScrollController.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/angular/controller/infiniteScrollController.js b/js/angular/controller/infiniteScrollController.js index 91797c55975..f461a32efa4 100644 --- a/js/angular/controller/infiniteScrollController.js +++ b/js/angular/controller/infiniteScrollController.js @@ -45,7 +45,8 @@ function($scope, $attrs, $element, $timeout) { $timeout(function() { if (self.jsScrolling) self.scrollView.resize(); // only check bounds again immediately if the page isn't cached (scroll el has height) - if (self.scrollView.__container && self.scrollView.__container.offsetHeight > 0) { + if ((self.jsScrolling && self.scrollView.__container && self.scrollView.__container.offsetHeight > 0) || + !self.jsScrolling) { self.checkBounds(); } }, 30, false);