Index: trunk/extensions/ProofreadPage/SpecialPagesWithoutScans.php |
— | — | @@ -58,20 +58,18 @@ |
59 | 59 | } |
60 | 60 | $linkBatch->addObj( $dp ); |
61 | 61 | } else { |
62 | | - # Get all the templates linked from the Mediawiki:Disambiguationspage |
63 | | - $disPageObj = Title::makeTitleSafe( NS_MEDIAWIKI, 'disambiguationspage' ); |
64 | | - $res = $dbr->select( |
65 | | - array('pagelinks', 'page'), |
66 | | - 'pl_title', |
67 | | - array('page_id = pl_from', 'pl_namespace' => NS_TEMPLATE, |
68 | | - 'page_namespace' => $disPageObj->getNamespace(), 'page_title' => $disPageObj->getDBkey()), |
69 | | - __METHOD__ ); |
| 62 | + # Get all the templates linked from the Mediawiki:Disambiguationspage |
| 63 | + $disPageObj = Title::makeTitleSafe( NS_MEDIAWIKI, 'disambiguationspage' ); |
| 64 | + $res = $dbr->select( |
| 65 | + array('pagelinks', 'page'), |
| 66 | + 'pl_title', |
| 67 | + array('page_id = pl_from', 'pl_namespace' => NS_TEMPLATE, |
| 68 | + 'page_namespace' => $disPageObj->getNamespace(), 'page_title' => $disPageObj->getDBkey()), |
| 69 | + __METHOD__ ); |
70 | 70 | |
71 | | - foreach ( $res as $row ) { |
72 | | - $linkBatch->addObj( Title::makeTitle( NS_TEMPLATE, $row->pl_title )); |
73 | | - } |
74 | | - |
75 | | - $dbr->freeResult( $res ); |
| 71 | + foreach ( $res as $row ) { |
| 72 | + $linkBatch->addObj( Title::makeTitle( NS_TEMPLATE, $row->pl_title )); |
| 73 | + } |
76 | 74 | } |
77 | 75 | return $linkBatch->constructSet( 'tl', $dbr ); |
78 | 76 | } |