Index: trunk/phase3/docs/hooks.txt |
— | — | @@ -1564,6 +1564,7 @@ |
1565 | 1565 | &$join_conds: join conditions for the tables |
1566 | 1566 | $opts: FormOptions for this request |
1567 | 1567 | &$query_options: array of options for the database request |
| 1568 | +&$select: String '*' or array of columns to select |
1568 | 1569 | |
1569 | 1570 | 'SpecialSearchGomatch': called when user clicked the "Go" button and the target |
1570 | 1571 | exists |
Index: trunk/phase3/includes/specials/SpecialRecentchangeslinked.php |
— | — | @@ -114,7 +114,7 @@ |
115 | 115 | $query_options, $opts['tagfilter'] ); |
116 | 116 | } |
117 | 117 | |
118 | | - if ( !wfRunHooks( 'SpecialRecentChangesQuery', array( &$conds, &$tables, &$join_conds, $opts, &$query_options ) ) ) |
| 118 | + if ( !wfRunHooks( 'SpecialRecentChangesQuery', array( &$conds, &$tables, &$join_conds, $opts, &$query_options, &$select ) ) ) |
119 | 119 | return false; |
120 | 120 | |
121 | 121 | if( $ns == NS_CATEGORY && !$showlinkedto ) { |
Index: trunk/phase3/includes/specials/SpecialRecentchanges.php |
— | — | @@ -311,6 +311,7 @@ |
312 | 312 | $dbr = wfGetDB( DB_SLAVE ); |
313 | 313 | $limit = $opts['limit']; |
314 | 314 | $namespace = $opts['namespace']; |
| 315 | + $select = '*'; |
315 | 316 | $invert = $opts['invert']; |
316 | 317 | |
317 | 318 | // JOIN on watchlist for users |
— | — | @@ -333,7 +334,7 @@ |
334 | 335 | ); |
335 | 336 | } |
336 | 337 | |
337 | | - if ( !wfRunHooks( 'SpecialRecentChangesQuery', array( &$conds, &$tables, &$join_conds, $opts, &$query_options ) ) ) |
| 338 | + if ( !wfRunHooks( 'SpecialRecentChangesQuery', array( &$conds, &$tables, &$join_conds, $opts, &$query_options, &$select ) ) ) |
338 | 339 | return false; |
339 | 340 | |
340 | 341 | // Don't use the new_namespace_time timestamp index if: |
— | — | @@ -353,7 +354,7 @@ |
354 | 355 | // We have a new_namespace_time index! UNION over new=(0,1) and sort result set! |
355 | 356 | } else { |
356 | 357 | // New pages |
357 | | - $sqlNew = $dbr->selectSQLText( $tables, '*', |
| 358 | + $sqlNew = $dbr->selectSQLText( $tables, $select, |
358 | 359 | array( 'rc_new' => 1 ) + $conds, |
359 | 360 | __METHOD__, |
360 | 361 | array( 'ORDER BY' => 'rc_timestamp DESC', 'LIMIT' => $limit, |