Thiemo Kreuz (WMDE) has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/399417 )
Change subject: Remove some non-helpful comments
......................................................................
Remove some non-helpful comments
This patch removes some outdated or misplaced cruft and duplications
that do not help making the code better readable.
Change-Id: I3548eea390ec5c1e71e1a7cfc56eb69a7a937419
---
M DPL.php
M DPLArticle.php
M DPLListMode.php
M DPLMain.php
M DPLSetup.php
M DPLVariables.php
M DynamicPageList.php
M DynamicPageListInclude.php
M DynamicPageListMigration.php
9 files changed, 11 insertions(+), 34 deletions(-)
git pull
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DynamicPageList
refs/changes/17/399417/1
diff --git a/DPL.php b/DPL.php
index 8f7cba9..d8ad237 100644
--- a/DPL.php
+++ b/DPL.php
@@ -1,6 +1,4 @@
<?php
-// this file is UTF-8 encoded and contains some special characters.
-// Editing this file with an ASCII editor will potentially destroy it!
class DPL {
diff --git a/DPLArticle.php b/DPLArticle.php
index f35fa8f..7b467b1 100644
--- a/DPLArticle.php
+++ b/DPLArticle.php
@@ -1,8 +1,11 @@
<?php
-// Simple Article/Page class with properties used in the DPL
+/**
+ * Simple Article/Page class with properties used in the DPL
+ */
class DPLArticle {
- public $mTitle = ''; // title
+
+ public $mTitle = '';
public $mNamespace = -1; // namespace (number)
public $mID = 0; // page_id
public $mSelTitle = ''; // selected title of initial page
@@ -30,4 +33,5 @@
$this->mTitle = $title;
$this->mNamespace = $namespace;
}
+
}
diff --git a/DPLListMode.php b/DPLListMode.php
index 51651dc..00a5370 100644
--- a/DPLListMode.php
+++ b/DPLListMode.php
@@ -1,6 +1,7 @@
<?php
class DPLListMode {
+
public $name;
public $sListStart = '';
public $sListEnd = '';
@@ -84,4 +85,5 @@
break;
}
}
+
}
diff --git a/DPLMain.php b/DPLMain.php
index c570fe1..fb3952d 100644
--- a/DPLMain.php
+++ b/DPLMain.php
@@ -1,17 +1,9 @@
<?php
-// this file is UTF-8 encoded and contains some special characters.
-// Editing this file with an ASCII editor will potentially destroy it!
class DPLMain {
- /*
============================================================================================================
- /
MAIN FUNCTION
- /
============================================================================================================
- */
-
// The real callback function for converting the input text to wiki
text output
public static function dynamicPageList( $input, $params, $parser,
&$bReset, $calledInMode ) {
- // Output
$output = '';
error_reporting( E_ALL );
@@ -3562,4 +3554,5 @@
$articles[$a] = $cArticles[$key];
}
}
+
}
diff --git a/DPLSetup.php b/DPLSetup.php
index 9d2ef16..46c9a2d 100644
--- a/DPLSetup.php
+++ b/DPLSetup.php
@@ -1,6 +1,5 @@
<?php
-// this file is UTF-8 encoded and contains some special characters.
-// Editing this file with an ASCII editor will potentially destroy it!
+
/**
* This file handles the configuration setup for the DynamicPageList extension
of MediaWiki.
* This code is released under the GNU General Public License.
@@ -420,7 +419,6 @@
* re-merged all changes from SVN since DPL 1.8.6
*
* when making changes here you must update the version field in
DynamicPageList.php and DynamicPageListMigration.php !
- *
*/
function ExtDynamicPageList__languageGetMagic( &$magicWords, $langCode ) {
@@ -445,7 +443,6 @@
// Debug stuff
- // FATAL
const FATAL_WRONGNS = 1; // $0:
'namespace' or 'notnamespace'
// $1: wrong
parameter given by user
// $3: list of
possible titles of namespaces (except pseudo-namespaces: Media, Special)
@@ -475,10 +472,6 @@
const FATAL_OPENREFERENCES = 12;
- // ERROR
-
- // WARN
-
const WARN_UNKNOWNPARAM = 13; // $0: unknown
parameter given by user
// $1: list of DPL
available parameters separated by ', '
@@ -499,15 +492,7 @@
const WARN_TRANSCLUSIONLOOP = 20; // $0: title of
page that creates an infinite transclusion loop
- // INFO
-
- // DEBUG
-
const DEBUG_QUERY = 21; // $0: SQL
query executed to generate the dynamic page list
-
- // TRACE
-
// Output formatting
- // $1: number of
articles
/**
* Extension options
diff --git a/DPLVariables.php b/DPLVariables.php
index cd72b63..6521f61 100644
--- a/DPLVariables.php
+++ b/DPLVariables.php
@@ -1,6 +1,7 @@
<?php
class DPLVariables {
+
static $memoryVar = array();
static $memoryArray = array();
diff --git a/DynamicPageList.php b/DynamicPageList.php
index 622f1a3..6ccec73 100644
--- a/DynamicPageList.php
+++ b/DynamicPageList.php
@@ -48,7 +48,6 @@
revision level
- level=4 adds a few additional features which are useful for private
websites (like batch updates)
but should not be made available on huge public websites.
-
*/
// we register the tag <dpl> and function #dpl
@@ -81,4 +80,3 @@
// use full functionality by default
ExtDynamicPageList::setFunctionalRichness( 4 );
-
diff --git a/DynamicPageListInclude.php b/DynamicPageListInclude.php
index 167df74..0142b3f 100644
--- a/DynamicPageListInclude.php
+++ b/DynamicPageListInclude.php
@@ -1,6 +1,4 @@
<?php
-// this file is UTF-8 encoded and contains some special characters.
-// Editing this file with an ASCII editor will potentially destroy it!
/**#@+
* This is a modified and enhanced copy of a mediawiki extension called
@@ -97,7 +95,6 @@
* UNIQ-QINU-Bug: replaced parser->replaceVariables by
parser->preprocess
* @version 2.0
* added %ARGS% to template surrogate call
-
*/
class DPLInclude {
diff --git a/DynamicPageListMigration.php b/DynamicPageListMigration.php
index 5038e4e..d1f5c56 100644
--- a/DynamicPageListMigration.php
+++ b/DynamicPageListMigration.php
@@ -25,7 +25,6 @@
This will open the door to a rich set of additional functionality.
You can decide how much of that additional functionality you want to offer
to your users.
See the documentation in DynamicPageList.php for more details.
-
*/
if ( !defined( 'MEDIAWIKI' ) ) {
--
To view, visit https://gerrit.wikimedia.org/r/399417
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I3548eea390ec5c1e71e1a7cfc56eb69a7a937419
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/DynamicPageList
Gerrit-Branch: master
Gerrit-Owner: Thiemo Kreuz (WMDE) <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits