summaryrefslogtreecommitdiff
path: root/includes/api/ApiQueryProtectedTitles.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/api/ApiQueryProtectedTitles.php')
-rw-r--r--includes/api/ApiQueryProtectedTitles.php10
1 files changed, 2 insertions, 8 deletions
diff --git a/includes/api/ApiQueryProtectedTitles.php b/includes/api/ApiQueryProtectedTitles.php
index ff703cda..44cc1d32 100644
--- a/includes/api/ApiQueryProtectedTitles.php
+++ b/includes/api/ApiQueryProtectedTitles.php
@@ -24,11 +24,6 @@
* @file
*/
-if ( !defined( 'MEDIAWIKI' ) ) {
- // Eclipse helper - will be ignored in production
- require_once( 'ApiQueryBase.php' );
-}
-
/**
* Query module to enumerate all create-protected pages.
*
@@ -112,8 +107,7 @@ class ApiQueryProtectedTitles extends ApiQueryGeneratorBase {
}
if ( isset( $prop['parsedcomment'] ) ) {
- global $wgUser;
- $vals['parsedcomment'] = $wgUser->getSkin()->formatComment( $row->pt_reason, $title );
+ $vals['parsedcomment'] = Linker::formatComment( $row->pt_reason, $title );
}
if ( isset( $prop['expiry'] ) ) {
@@ -224,7 +218,7 @@ class ApiQueryProtectedTitles extends ApiQueryGeneratorBase {
return 'List all titles protected from creation';
}
- protected function getExamples() {
+ public function getExamples() {
return array(
'api.php?action=query&list=protectedtitles',
);