зеркало из https://github.com/nextcloud/news.git
debug
This commit is contained in:
Родитель
0dbcbb6f8b
Коммит
13f9849a68
|
@ -84,11 +84,11 @@ $rootScope, $q) ->
|
|||
do (lastChange, offset) =>
|
||||
successCallbackWrapper = (data) =>
|
||||
console.log data
|
||||
console.log data.items
|
||||
console.log data.data.items
|
||||
console.log offset
|
||||
console.log lastChange
|
||||
console.log @_lastFeedChange
|
||||
if data.items.length == 0 &&
|
||||
if data.data.items.length == 0 &&
|
||||
lastChange == @_lastFeedChange &&
|
||||
offset != 0
|
||||
@_preventUselessAutoPageRequest = true
|
||||
|
|
|
@ -2786,11 +2786,11 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
|
|||
(function(lastChange, offset) {
|
||||
return successCallbackWrapper = function(data) {
|
||||
console.log(data);
|
||||
console.log(data.items);
|
||||
console.log(data.data.items);
|
||||
console.log(offset);
|
||||
console.log(lastChange);
|
||||
console.log(_this._lastFeedChange);
|
||||
if (data.items.length === 0 && lastChange === _this._lastFeedChange && offset !== 0) {
|
||||
if (data.data.items.length === 0 && lastChange === _this._lastFeedChange && offset !== 0) {
|
||||
_this._preventUselessAutoPageRequest = true;
|
||||
}
|
||||
onSuccess(data);
|
||||
|
|
|
@ -76,7 +76,8 @@ describe 'Persistence', ->
|
|||
|
||||
it 'should reset the autopage lock when loading a new feed', =>
|
||||
data =
|
||||
items: []
|
||||
data:
|
||||
items: []
|
||||
called = 0
|
||||
@req.get.andCallFake (route, params) ->
|
||||
params.onSuccess(data)
|
||||
|
@ -93,7 +94,8 @@ describe 'Persistence', ->
|
|||
|
||||
xit 'should not send autopage request if reqeust returned nothing', =>
|
||||
data =
|
||||
items: []
|
||||
data:
|
||||
items: []
|
||||
called = 0
|
||||
@req.get.andCallFake (route, params) ->
|
||||
params.onSuccess(data)
|
||||
|
|
Загрузка…
Ссылка в новой задаче