Index: trunk/phase3/includes/specials/SpecialExport.php |
— | — | @@ -68,7 +68,9 @@ |
69 | 69 | * during the export in a single query. |
70 | 70 | */ |
71 | 71 | $catpages = $this->getPagesFromCategory( $t ); |
72 | | - if ( $catpages ) $page .= "\n" . implode( "\n", $catpages ); |
| 72 | + if ( $catpages ) { |
| 73 | + $page .= "\n" . implode( "\n", $catpages ); |
| 74 | + } |
73 | 75 | } |
74 | 76 | } |
75 | 77 | } |
— | — | @@ -81,7 +83,9 @@ |
82 | 84 | * Same implementation as above, so same @todo |
83 | 85 | */ |
84 | 86 | $nspages = $this->getPagesFromNamespace( $nsindex ); |
85 | | - if ( $nspages ) $page .= "\n" . implode( "\n", $nspages ); |
| 87 | + if ( $nspages ) { |
| 88 | + $page .= "\n" . implode( "\n", $nspages ); |
| 89 | + } |
86 | 90 | } |
87 | 91 | } |
88 | 92 | else if( $wgRequest->wasPosted() && $par == '' ) { |
— | — | @@ -118,7 +122,9 @@ |
119 | 123 | } |
120 | 124 | } |
121 | 125 | |
122 | | - if( $page != '' ) $this->doExport = true; |
| 126 | + if( $page != '' ) { |
| 127 | + $this->doExport = true; |
| 128 | + } |
123 | 129 | } else { |
124 | 130 | // Default to current-only for GET requests. |
125 | 131 | $page = $wgRequest->getText( 'pages', $par ); |
— | — | @@ -130,7 +136,9 @@ |
131 | 137 | $history = WikiExporter::CURRENT; |
132 | 138 | } |
133 | 139 | |
134 | | - if( $page != '' ) $this->doExport = true; |
| 140 | + if( $page != '' ) { |
| 141 | + $this->doExport = true; |
| 142 | + } |
135 | 143 | } |
136 | 144 | |
137 | 145 | if( !$wgExportAllowHistory ) { |
— | — | @@ -139,7 +147,9 @@ |
140 | 148 | } |
141 | 149 | |
142 | 150 | $list_authors = $wgRequest->getCheck( 'listauthors' ); |
143 | | - if ( !$this->curonly || !$wgExportAllowListContributors ) $list_authors = false ; |
| 151 | + if ( !$this->curonly || !$wgExportAllowListContributors ) { |
| 152 | + $list_authors = false ; |
| 153 | + } |
144 | 154 | |
145 | 155 | if ( $this->doExport ) { |
146 | 156 | $wgOut->disable(); |
— | — | @@ -286,8 +296,12 @@ |
287 | 297 | }*/ |
288 | 298 | #Bug 8824: Only export pages the user can read |
289 | 299 | $title = Title::newFromText( $page ); |
290 | | - if( is_null( $title ) ) continue; #TODO: perhaps output an <error> tag or something. |
291 | | - if( !$title->userCanRead() ) continue; #TODO: perhaps output an <error> tag or something. |
| 300 | + if( is_null( $title ) ) { |
| 301 | + continue; #TODO: perhaps output an <error> tag or something. |
| 302 | + } |
| 303 | + if( !$title->userCanRead() ) { |
| 304 | + continue; #TODO: perhaps output an <error> tag or something. |
| 305 | + } |
292 | 306 | |
293 | 307 | $exporter->pageByTitle( $title ); |
294 | 308 | } |
— | — | @@ -394,7 +408,7 @@ |
395 | 409 | |
396 | 410 | /** Expand a list of pages to include pages linked to from that page. */ |
397 | 411 | private function getPageLinks( $inputPages, $pageSet, $depth ) { |
398 | | - for(; $depth > 0; --$depth ) { |
| 412 | + for( ; $depth > 0; --$depth ) { |
399 | 413 | $pageSet = $this->getLinks( |
400 | 414 | $inputPages, $pageSet, 'pagelinks', |
401 | 415 | array( 'pl_namespace AS namespace', 'pl_title AS title' ), |