implemented action=purge for RC RSS feed. Not sure how usefull that is in production...
authorDaniel Kinzler <daniel@users.mediawiki.org>
Wed, 19 Sep 2007 20:06:06 +0000 (20:06 +0000)
committerDaniel Kinzler <daniel@users.mediawiki.org>
Wed, 19 Sep 2007 20:06:06 +0000 (20:06 +0000)
includes/SpecialRecentchanges.php

index 96425eb..2d70209 100644 (file)
@@ -332,6 +332,14 @@ function rcOutputFeed( $rows, $feedFormat, $limit, $hideminor, $lastmod ) {
                htmlspecialchars( wfMsgForContent( 'recentchanges-feed-description' ) ),
                $wgTitle->getFullUrl() );
 
+       //purge cache if requested
+       global $wgRequest, $wgUser;
+       $purge = $wgRequest->getVal( 'action' ) == 'purge';
+       if ( $purge && $wgUser->isAllowed('purge') ) {
+               $messageMemc->delete( $timekey );
+               $messageMemc->delete( $key );
+       }
+
        /**
         * Bumping around loading up diffs can be pretty slow, so where
         * possible we want to cache the feed output so the next visitor