http://www.mediawiki.org/wiki/Special:Code/MediaWiki/96180

Revision: 96180
Author:   dantman
Date:     2011-09-03 13:17:55 +0000 (Sat, 03 Sep 2011)
Log Message:
-----------
Use wfExpandUrl+PROTO_CANONICAL inside of getCanonicalURL instead of just 
prepending the url so this does not break on interwiki and action=render

Modified Paths:
--------------
    trunk/phase3/includes/Title.php

Modified: trunk/phase3/includes/Title.php
===================================================================
--- trunk/phase3/includes/Title.php     2011-09-03 13:16:59 UTC (rev 96179)
+++ trunk/phase3/includes/Title.php     2011-09-03 13:17:55 UTC (rev 96180)
@@ -1045,8 +1045,8 @@
         */
        public function getCanonicalURL( $query = '', $variant = false ) {
                global $wgCanonicalServer;
-               $url = $wgCanonicalServer . $this->getLocalURL( $query, 
$variant ) . $this->getFragmentForURL();
-               wfRunHooks( 'GetCanonicalURL', array( &$this, &$url, $query ) );
+               $url = wfExpandUrl( $this->getLocalURL( $query, $variant ) . 
$this->getFragmentForURL(), PROTO_CANONICAL );
+               wfRunHooks( '', array( &$this, &$url, $query ) );
                return $url;
        }
 


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

Reply via email to