Jdlrobson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/127291

Change subject: Fix infinite scroll on uploads page
......................................................................

Fix infinite scroll on uploads page

This seems to have been broken by core change 
I4c9f8c0c2bfd831755d4fa20a18f93fef1effd28
(see bug 24782) which got merged a week ago (explains why English Wikipedia not 
effected)

The new API request doesn't honour the old method. Shouldn't there have been a 
deprecation
notice and some compatible fallback?

Bug: 64094
Change-Id: Ic77b5f8dc382101a7af3f43a36bb2d8271ee60e1
---
M javascripts/specials/uploads.js
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend 
refs/changes/91/127291/1

diff --git a/javascripts/specials/uploads.js b/javascripts/specials/uploads.js
index feffc1e..91f2cfd 100644
--- a/javascripts/specials/uploads.js
+++ b/javascripts/specials/uploads.js
@@ -19,7 +19,7 @@
                },
                getPhotos: function() {
                        var self = this, result = $.Deferred();
-
+                       // FIXME: Don't simply use this.endTimestamp as 
initially this value is undefined
                        if ( this.endTimestamp !== false ) {
                                this.get( {
                                        action: 'query',
@@ -28,7 +28,7 @@
                                        gaidir: 'descending',
                                        gaiuser: userName,
                                        gailimit: this.limit,
-                                       gaistart: this.endTimestamp,
+                                       gaicontinue: this.endTimestamp,
                                        prop: 'imageinfo',
                                        origin: corsUrl ? M.getOrigin() : 
undefined,
                                        // FIXME: [API] have to request 
timestamp since api returns an object
@@ -45,7 +45,7 @@
                                                        return a.timestamp < 
b.timestamp ? 1 : -1;
                                                } );
                                                if ( resp['query-continue'] ) {
-                                                       self.endTimestamp = 
resp['query-continue'].allimages.gaistart;
+                                                       self.endTimestamp = 
resp['query-continue'].allimages.gaicontinue;
                                                } else {
                                                        self.endTimestamp = 
false;
                                                }

-- 
To view, visit https://gerrit.wikimedia.org/r/127291
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic77b5f8dc382101a7af3f43a36bb2d8271ee60e1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to