Niharika29 has uploaded a new change for review.

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

Change subject: Fix Gather:Special/all/recent pagination
......................................................................

Fix Gather:Special/all/recent pagination

Bug:T103496
Change-Id: I270e25adba7f850b7bb92961583bc84c524e0da0
---
M resources/ext.gather.api/CollectionsApi.js
M resources/ext.gather.collections.list/CollectionsList.js
2 files changed, 5 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather 
refs/changes/41/220841/1

diff --git a/resources/ext.gather.api/CollectionsApi.js 
b/resources/ext.gather.api/CollectionsApi.js
index 1d1cc56..3ad995f 100644
--- a/resources/ext.gather.api/CollectionsApi.js
+++ b/resources/ext.gather.api/CollectionsApi.js
@@ -189,9 +189,11 @@
                                        action: 'query',
                                        list: 'lists',
                                        lstlimit: 50,
-                                       lsttitle: page ? page.getTitle() : null,
                                        lstprop: 
'label|description|public|image|count|owner'
                                } );
+                       if ( page ) {
+                               args['lstitle'] = page.getTitle();
+                       }
                        return this.get( args ).then( function ( resp ) {
                                var result = {};
                                if ( resp['query-continue'] ) {
diff --git a/resources/ext.gather.collections.list/CollectionsList.js 
b/resources/ext.gather.collections.list/CollectionsList.js
index 133c75a..8b3eed1 100644
--- a/resources/ext.gather.collections.list/CollectionsList.js
+++ b/resources/ext.gather.collections.list/CollectionsList.js
@@ -104,7 +104,8 @@
                _apiCallByMode: function () {
                        if ( this.options.mode === 'recent' ) {
                                return this.api.getCollections( null, $.extend( 
this.continueArgs, {
-                                               lstminitems: 4
+                                               lstminitems: 4,
+                                               lstmode = 'allpublic'
                                        } ) );
                        } else {
                                return this.api.getCurrentUsersCollections( 
this.options.owner, null, this.continueArgs );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I270e25adba7f850b7bb92961583bc84c524e0da0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Niharika29 <niharikakohl...@gmail.com>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to