Use mw.util.getUrl( null ) to get the default mw.config.get( 'wgPageName' )
authorFomafix <fomafix@googlemail.com>
Thu, 19 Sep 2019 18:39:57 +0000 (20:39 +0200)
committerFomafix <fomafix@googlemail.com>
Thu, 19 Sep 2019 18:39:57 +0000 (20:39 +0200)
Change-Id: If802b23285762b0eb0d01eba7fd52761dcf9fb86

resources/src/mediawiki.page.image.pagination.js

index 4541c58..a0ac0ca 100644 (file)
                        // Generate the same URL on client side as the one generated in ImagePage::openShowImage.
                        // We avoid using the URL in the link directly since it could have been manipulated (T68608)
                        page = Number( mw.util.getParamValue( 'page', this.href ) );
-                       url = mw.util.getUrl( mw.config.get( 'wgPageName' ), { page: page } );
+                       url = mw.util.getUrl( null, { page: page } );
 
                        switchPage( url );
                        e.preventDefault();