mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateData
synced 2024-11-11 16:59:25 +00:00
Remove all references to TemplateInfo
Change-Id: I5ffc8f75140a2c372fc1c64509b13a534fe07479
This commit is contained in:
parent
8dc157bc09
commit
7bf85a39a1
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
/**
|
||||
* Hooks for TemplateInfo extension
|
||||
* Hooks for TemplateData extension
|
||||
*
|
||||
* @file
|
||||
* @ingroup Extensions
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
<?php
|
||||
/**
|
||||
* TemplateInfo extension.
|
||||
* TemplateData extension.
|
||||
*
|
||||
* @file
|
||||
* @ingroup Extensions
|
||||
*/
|
||||
|
||||
if ( version_compare( $wgVersion, '1.20', '<' ) ) {
|
||||
echo "Extension:TemplateInfo requires MediaWiki 1.20 or higher.\n";
|
||||
echo "Extension:TemplateData requires MediaWiki 1.20 or higher.\n";
|
||||
exit( 1 );
|
||||
}
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ class TemplateDataBlob {
|
|||
private $data;
|
||||
|
||||
/**
|
||||
* @var Status: Cache of TemplateInfo::validate
|
||||
* @var Status: Cache of TemplateDataBlob::parse
|
||||
*/
|
||||
private $status;
|
||||
|
||||
|
@ -50,7 +50,7 @@ class TemplateDataBlob {
|
|||
* Parse and validate passed JSON (possibly gzip-compressed) and create a TemplateDataBlob object.
|
||||
*
|
||||
* @param string $json
|
||||
* @return TemplateInfo
|
||||
* @return TemplateDataBlob
|
||||
*/
|
||||
public static function newFromDatabase( $json ) {
|
||||
// Handle GZIP compression. \037\213 is the header for GZIP files.
|
||||
|
|
|
@ -394,7 +394,7 @@ class TemplateDataBlobTest extends MediaWikiTestCase {
|
|||
// Compress JSON to trigger the code pass in newFromDatabase that ends
|
||||
// up calling gzdecode().
|
||||
$gzJson = gzencode( '{}' );
|
||||
$templateInfo = TemplateDataBlob::newFromDatabase( $gzJson );
|
||||
$this->assertInstanceOf( 'TemplateDataBlob', $templateInfo );
|
||||
$templateData = TemplateDataBlob::newFromDatabase( $gzJson );
|
||||
$this->assertInstanceOf( 'TemplateDataBlob', $templateData );
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue