From ae7d7676fb69e9688128c35a20990075f52bb7bf Mon Sep 17 00:00:00 2001 From: Roan Kattouw Date: Wed, 3 Aug 2011 13:11:42 +0000 Subject: [PATCH] Fix r93820: PROT_ -> PROTO_ --- includes/HttpFunctions.php | 2 +- includes/OutputPage.php | 2 +- includes/User.php | 2 +- includes/filerepo/ForeignAPIRepo.php | 2 +- includes/libs/CSSMin.php | 2 +- includes/parser/CoreParserFunctions.php | 2 +- includes/resourceloader/ResourceLoaderFileModule.php | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/includes/HttpFunctions.php b/includes/HttpFunctions.php index df6dd49fdb..de484d2c11 100644 --- a/includes/HttpFunctions.php +++ b/includes/HttpFunctions.php @@ -32,7 +32,7 @@ class Http { * @return Mixed: (bool)false on failure or a string on success */ public static function request( $method, $url, $options = array() ) { - $url = wfExpandUrl( $url, PROT_HTTP ); + $url = wfExpandUrl( $url, PROTO_HTTP ); wfDebug( "HTTP: $method: $url\n" ); $options['method'] = strtoupper( $method ); diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 0164ad3271..b93e20a2ed 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -2820,7 +2820,7 @@ $templates 'type' => 'application/rsd+xml', // Output a protocol-relative URL here if $wgServer is protocol-relative // Whether RSD accepts relative or protocol-relative URLs is completely undocumented, though - 'href' => wfExpandUrl( wfAppendQuery( wfScript( 'api' ), array( 'action' => 'rsd' ) ), PROT_RELATIVE ), + 'href' => wfExpandUrl( wfAppendQuery( wfScript( 'api' ), array( 'action' => 'rsd' ) ), PROTO_RELATIVE ), ) ); } diff --git a/includes/User.php b/includes/User.php index ee9a736a34..47e2462b7e 100644 --- a/includes/User.php +++ b/includes/User.php @@ -3321,7 +3321,7 @@ class User { '$1', "Special:$page/$token", $wgArticlePath ), - PROT_HTTP + PROTO_HTTP ); } diff --git a/includes/filerepo/ForeignAPIRepo.php b/includes/filerepo/ForeignAPIRepo.php index 46643849e4..e0109da165 100644 --- a/includes/filerepo/ForeignAPIRepo.php +++ b/includes/filerepo/ForeignAPIRepo.php @@ -370,7 +370,7 @@ class ForeignAPIRepo extends FileRepo { public static function httpGet( $url, $timeout = 'default', $options = array() ) { $options['timeout'] = $timeout; /* Http::get */ - $url = wfExpandUrl( $url, PROT_HTTP ); + $url = wfExpandUrl( $url, PROTO_HTTP ); wfDebug( "ForeignAPIRepo: HTTP GET: $url\n" ); $options['method'] = "GET"; diff --git a/includes/libs/CSSMin.php b/includes/libs/CSSMin.php index 8fd83d681f..200240853b 100644 --- a/includes/libs/CSSMin.php +++ b/includes/libs/CSSMin.php @@ -138,7 +138,7 @@ class CSSMin { $expanded = wfExpandUrl( $match['file'][0] ); $origLength = strlen( $match['file'][0] ); $lengthIncrease = strlen( $expanded ) - $origLength; - $source = substr_replace( $source, wfExpandUrl( $match['file'][0], PROT_RELATIVE ), + $source = substr_replace( $source, wfExpandUrl( $match['file'][0], PROTO_RELATIVE ), $match['file'][1], $origLength, ); } diff --git a/includes/parser/CoreParserFunctions.php b/includes/parser/CoreParserFunctions.php index 48cee4c0e4..eda577dc47 100644 --- a/includes/parser/CoreParserFunctions.php +++ b/includes/parser/CoreParserFunctions.php @@ -723,7 +723,7 @@ class CoreParserFunctions { // ... and we can if ( $mto && !$mto->isError() ) { // ... change the URL to point to a thumbnail. - $url = wfExpandUrl( $mto->getUrl(), PROT_RELATIVE ); + $url = wfExpandUrl( $mto->getUrl(), PROTO_RELATIVE ); } } if ( $option == 'nowiki' ) { diff --git a/includes/resourceloader/ResourceLoaderFileModule.php b/includes/resourceloader/ResourceLoaderFileModule.php index 59ca6dce15..8d50dcaf3e 100644 --- a/includes/resourceloader/ResourceLoaderFileModule.php +++ b/includes/resourceloader/ResourceLoaderFileModule.php @@ -206,7 +206,7 @@ class ResourceLoaderFileModule extends ResourceLoaderModule { } // Make sure the remote base path is a complete valid URL, // but possibly protocol-relative to avoid cache pollution - $this->remoteBasePath = wfExpandUrl( $this->remoteBasePath, PROT_RELATIVE ); + $this->remoteBasePath = wfExpandUrl( $this->remoteBasePath, PROTO_RELATIVE ); } /** -- 2.20.1