http://www.mediawiki.org/wiki/Special:Code/MediaWiki/84629
Revision: 84629
Author: tparscal
Date: 2011-03-23 19:45:45 +0000 (Wed, 23 Mar 2011)
Log Message:
-----------
Added comments to $pageId and $rev variables within a loop to help improve code
clarity
Modified Paths:
--------------
trunk/extensions/ArticleFeedback/api/ApiQueryArticleFeedback.php
Modified: trunk/extensions/ArticleFeedback/api/ApiQueryArticleFeedback.php
===================================================================
--- trunk/extensions/ArticleFeedback/api/ApiQueryArticleFeedback.php
2011-03-23 19:37:39 UTC (rev 84628)
+++ trunk/extensions/ArticleFeedback/api/ApiQueryArticleFeedback.php
2011-03-23 19:45:45 UTC (rev 84629)
@@ -44,12 +44,11 @@
$rev = null;
foreach ( $res as $i => $row ) {
+ // All the revs and pageIds will be the same for all
rows, these are shortcuts
$pageId = $row->aap_page_id;
+ // This is special however, because we need this data
later for expired calculation
+ $rev = $row->aap_revision;
- if ( is_null( $rev ) ) {
- $rev = $row->aap_revision;
- }
-
if ( !isset( $ratings[$pageId] ) ) {
$page = array(
'pageid' => $pageId,
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs