Index: trunk/phase3/includes/ProtectionForm.php |
— | — | @@ -76,11 +76,12 @@ |
77 | 77 | } |
78 | 78 | |
79 | 79 | function execute() { |
80 | | - global $wgRequest; |
| 80 | + global $wgRequest, $wgOut; |
81 | 81 | if( $wgRequest->wasPosted() ) { |
82 | 82 | if( $this->save() ) { |
83 | | - global $wgOut; |
84 | | - $wgOut->redirect( $this->mTitle->getFullUrl( 'redirect=no' ) ); |
| 83 | + $article = new Article( $this->mTitle ); |
| 84 | + $q = $article->isRedirect() ? 'redirect=no' : ''; |
| 85 | + $wgOut->redirect( $this->mTitle->getFullUrl( $q ) ); |
85 | 86 | } |
86 | 87 | } else { |
87 | 88 | $this->show(); |