https://www.mediawiki.org/wiki/Special:Code/MediaWiki/114171

Revision: 114171
Author:   wikinaut
Date:     2012-03-19 19:05:40 +0000 (Mon, 19 Mar 2012)
Log Message:
-----------
removed the redundant code for handling tracking categories. By using '-' for 
the message text etherpadlite-tracking-category , this can be disabled easily.

Modified Paths:
--------------
    trunk/extensions/EtherpadLite/EtherpadLite.php
    trunk/extensions/EtherpadLite/EtherpadLite_body.php

Modified: trunk/extensions/EtherpadLite/EtherpadLite.php
===================================================================
--- trunk/extensions/EtherpadLite/EtherpadLite.php      2012-03-19 19:02:42 UTC 
(rev 114170)
+++ trunk/extensions/EtherpadLite/EtherpadLite.php      2012-03-19 19:05:40 UTC 
(rev 114171)
@@ -64,7 +64,7 @@
        'path' => __FILE__,
        'name' => 'EtherpadLite',
        'author' => array( 'Thomas Gries' ),
-       'version' => '1.12 20120309',
+       'version' => '1.13 20120319',
        'url' => 'https://www.mediawiki.org/wiki/Extension:EtherpadLite',
        'descriptionmsg' => 'etherpadlite-desc',
 );
@@ -104,20 +104,3 @@
 
 # include "*" if you expressly want to allow all urls (you should not do this)
 # $wgEtherpadLiteUrlWhitelist = array( "*" );
-
-// If you want to see images in feed items, then you need to globally allow
-// image tags in your wiki by using the MediaWiki parameter; default: false
-// $wgAllowImageTag = true;
-
-// Parameter to enable the automatic tracking category
-// for all pages using this parser extension
-//
-// Category name [[MediaWiki:etherpadlite-tracking-category]] (default)
-// $wgEtherpadLiteTrackingCategory = true;
-//
-// you can assign a specific category name 
[[MediaWiki:Etherpadlite-mycategory]]
-// $wgEtherpadLiteTrackingCategory = 'etherpadlite-mycategory';
-//
-// you can disable the use of a tracking category
-// $wgEtherpadLiteTrackingCategory = false;
-$wgEtherpadLiteTrackingCategory = true;

Modified: trunk/extensions/EtherpadLite/EtherpadLite_body.php
===================================================================
--- trunk/extensions/EtherpadLite/EtherpadLite_body.php 2012-03-19 19:02:42 UTC 
(rev 114170)
+++ trunk/extensions/EtherpadLite/EtherpadLite_body.php 2012-03-19 19:05:40 UTC 
(rev 114171)
@@ -39,7 +39,7 @@
                global $wgEtherpadLiteDefaultPadUrl, 
$wgEtherpadLiteDefaultWidth, $wgEtherpadLiteDefaultHeight,
                        $wgEtherpadLiteMonospacedFont, 
$wgEtherpadLiteShowControls, $wgEtherpadLiteShowLineNumbers,
                        $wgEtherpadLiteShowChat, 
$wgEtherpadLiteShowAuthorColors, $wgEtherpadLiteUrlWhitelist,
-                       $wgEtherpadLitePadsOnThisPage, 
$wgEtherpadLiteTrackingCategory;
+                       $wgEtherpadLitePadsOnThisPage;
 
                # check the user input
 
@@ -166,16 +166,8 @@
                        $sanitizedAttributes
                );
 
-               wfDebug( "EtherpadLite::EtherpadLiteRender $output\n" );
-
-               if ( $wgEtherpadLiteTrackingCategory === true ) {
-                       $parser->addTrackingCategory( 
'etherpadlite-tracking-category' );
-               } elseif ( is_string( $wgEtherpadLiteTrackingCategory ) ) {
-                       $parser->addTrackingCategory( 
$wgEtherpadLiteTrackingCategory );
-               }
-
+               $parser->addTrackingCategory( 'etherpadlite-tracking-category' 
);
                return $output;
-
        }
 
        /**


_______________________________________________
MediaWiki-CVS mailing list
MediaWiki-CVS@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to