fix some of RC rollback madness:
[lhc/web/wiklou.git] / includes / specials / SpecialRecentchanges.php
index bc7b1e9..9aec761 100644 (file)
@@ -285,7 +285,10 @@ class SpecialRecentChanges extends SpecialPage {
                        $join_conds['watchlist'] = array('LEFT JOIN',
                                "wl_user={$uid} AND wl_title=rc_title AND wl_namespace=rc_namespace");
                }
-
+               if ($wgUser->isAllowed("rollback")) {
+                       $tables[] = 'page';
+                       $join_conds['page'] = array('LEFT JOIN', 'rc_namespace=page_namespace AND rc_title=page_title AND rc_this_oldid=page_latest');
+               }
                // Tag stuff.
                $fields = array(); // Fields are * in this case, so let the function modify an empty array to keep it happy.
                ChangeTags::modifyDisplayQuery( $tables, $fields, $conds, $join_conds, $opts['tagfilter'] );