r85640 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r85639‎ | r85640 | r85641 >
Date:21:29, 7 April 2011
Author:jeroendedauw
Status:ok (Comments)
Tags:
Comment:
rem dead code
Modified paths:
  • /trunk/extensions/ReaderFeedback/ReaderFeedback.class.php (modified) (history)
  • /trunk/extensions/ReaderFeedback/ReaderFeedback.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ReaderFeedback/ReaderFeedback.class.php
@@ -55,31 +55,6 @@
5656 ################# Utility functions #################
5757
5858 /**
59 - * @param string $val
60 - * @return obj array
61 - * Get a memcache storage object
62 - */
63 - public static function makeMemcObj( $val ) {
64 - $data = (object) array();
65 - $data->value = $val;
66 - $data->time = wfTimestampNow();
67 - return $data;
68 - }
69 -
70 - /**
71 - * @param mixed $data Memc data returned
72 - * @param Article $article
73 - * @return mixed
74 - * Return memc value if not expired
75 - */
76 - public static function getMemcValue( $data, $article ) {
77 - if( is_object($data) && $data->time >= $article->getTouched() ) {
78 - return $data->value;
79 - }
80 - return false;
81 - }
82 -
83 - /**
8459 * @param Article $article
8560 * @param string $tag
8661 * @param bool $forUpdate, use master?
Index: trunk/extensions/ReaderFeedback/ReaderFeedback.php
@@ -40,7 +40,7 @@
4141
4242 # Allow readers to rate pages in these namespaces
4343 $wgFeedbackNamespaces = array();
44 -#$wgFeedbackNamespaces = array( NS_MAIN );
 44+
4545 # Reader feedback tags, positive and negative. [a-zA-Z] tag names only.
4646 # Each tag has five levels, which 3 being average. The tag names are
4747 # mapped to their weight. This is used to determine the "worst"/"best" pages.

Comments

#Comment by Aaron Schulz (talk | contribs)   23:26, 20 June 2011

The '#$wgFeedbackNamespaces = array( NS_MAIN );' was meant as an example though.

Status & tagging log