Index: trunk/extensions/Translate/SpecialManageGroups.php |
— | — | @@ -120,7 +120,7 @@ |
121 | 121 | 'class' => 'mw-translate-manage' |
122 | 122 | ); |
123 | 123 | |
124 | | - global $wgRequest; |
| 124 | + global $wgRequest, $wgLang; |
125 | 125 | if ( |
126 | 126 | $wgRequest->wasPosted() && |
127 | 127 | $wgRequest->getBool( 'process', false ) && |
— | — | @@ -202,8 +202,6 @@ |
203 | 203 | $changed[] = '<ul>'; |
204 | 204 | } |
205 | 205 | |
206 | | - global $wgRequest, $wgLang; |
207 | | - |
208 | 206 | $requestKey = str_replace( '.', '_', $key ); |
209 | 207 | $requestKey = str_replace( ' ', '_', $key ); |
210 | 208 | $action = $wgRequest->getVal( "action-$type-$key" ); |
— | — | @@ -306,7 +304,6 @@ |
307 | 305 | if ( $code === 'en' ) { |
308 | 306 | $this->out->addWikiMsg( 'translate-manage-intro-en' ); |
309 | 307 | } else { |
310 | | - global $wgLang; |
311 | 308 | $lang = TranslateUtils::getLanguageName( $code, false, $wgLang->getCode() ); |
312 | 309 | $this->out->addWikiMsg( 'translate-manage-intro-other', $lang ); |
313 | 310 | } |
Index: trunk/extensions/Translate/tag/SpecialPageTranslation.php |
— | — | @@ -60,7 +60,7 @@ |
61 | 61 | $page = TranslatablePage::newFromTitle( $title ); |
62 | 62 | $page->removeTags(); |
63 | 63 | $page->getTitle()->invalidateCache(); |
64 | | - global $wgUser; |
| 64 | + |
65 | 65 | $logger = new LogPage( 'pagetranslation' ); |
66 | 66 | $params = array( 'user' => $wgUser->getName() ); |
67 | 67 | $logger->addEntry( 'unmark', $page->getTitle(), null, array( serialize( $params ) ) ); |
Index: trunk/extensions/Translate/tag/SpecialPageTranslationMovePage.php |
— | — | @@ -141,9 +141,9 @@ |
142 | 142 | } |
143 | 143 | |
144 | 144 | protected function doNormalMovePage() { |
145 | | - global $action, $wgRequest; |
| 145 | + global $wgRequest; |
146 | 146 | $form = new MovePageForm( $this->oldTitle, $this->newTitle ); |
147 | | - if ( $action === 'submit' && $this->checkToken() && $wgRequest->wasPosted() ) { |
| 147 | + if ( 'submit' == $wgRequest->getVal( 'action' ) && $this->checkToken() && $wgRequest->wasPosted() ) { |
148 | 148 | $form->doSubmit(); |
149 | 149 | } else { |
150 | 150 | $form->showForm( '' ); |
— | — | @@ -478,4 +478,4 @@ |
479 | 479 | return $this->page->getTitle()->getSubpages(); |
480 | 480 | } |
481 | 481 | |
482 | | -} |
\ No newline at end of file |
| 482 | +} |
Index: trunk/extensions/Translate/Translate.php |
— | — | @@ -473,7 +473,6 @@ |
474 | 474 | if ( $wgCommandLineMode ) return true; |
475 | 475 | |
476 | 476 | $version = "3"; // Must be a string |
477 | | - global $wgMemc; |
478 | 477 | $memcKey = wfMemcKey( 'pt' ); |
479 | 478 | $ok = $wgMemc->get( $memcKey ); |
480 | 479 | |
— | — | @@ -534,7 +533,7 @@ |
535 | 534 | function wfAddNamespace( $id, $name ) { |
536 | 535 | global $wgExtraNamespaces, $wgContentNamespaces, |
537 | 536 | $wgTranslateMessageNamespaces, $wgNamespaceProtection, |
538 | | - $wgNamespacesWithSubpages; |
| 537 | + $wgNamespacesWithSubpages, $wgNamespacesToBeSearchedDefault; |
539 | 538 | |
540 | 539 | $constant = strtoupper( "NS_$name" ); |
541 | 540 | |
Index: trunk/extensions/Translate/utils/MessageWebImporter.php |
— | — | @@ -162,7 +162,7 @@ |
163 | 163 | $text = $diff->getDiff( '', '' ); |
164 | 164 | $type = 'changed'; |
165 | 165 | |
166 | | - global $wgRequest; |
| 166 | + global $wgRequest, $wgLang;; |
167 | 167 | |
168 | 168 | # Spaces don't seem to survive round trip in addition to dots |
169 | 169 | # which are silently handled in getVal |
— | — | @@ -175,8 +175,6 @@ |
176 | 176 | $changed[] = '<ul>'; |
177 | 177 | } |
178 | 178 | |
179 | | - global $wgLang; |
180 | | - |
181 | 179 | if ( $action === null ) { |
182 | 180 | $message = wfMsgExt( 'translate-manage-inconsistent', 'parseinline', wfEscapeWikiText( "action-$type-$key" ) ); |
183 | 181 | $changed[] = "<li>$message</li></ul>"; |
— | — | @@ -262,7 +260,6 @@ |
263 | 261 | if ( $code === 'en' ) { |
264 | 262 | $this->out->addWikiMsg( 'translate-manage-intro-en' ); |
265 | 263 | } else { |
266 | | - global $wgLang; |
267 | 264 | $lang = TranslateUtils::getLanguageName( $code, false, $wgLang->getCode() ); |
268 | 265 | $this->out->addWikiMsg( 'translate-manage-intro-other', $lang ); |
269 | 266 | } |