Index: trunk/extensions/LiquidThreads/classes/View.php |
— | — | @@ -309,11 +309,13 @@ |
310 | 310 | $thread = Threads::withId( intval( $operand ) ); |
311 | 311 | |
312 | 312 | // Yuck. |
313 | | - global $wgOut, $wgRequest; |
| 313 | + global $wgOut, $wgRequest, $wgTitle; |
314 | 314 | $oldOut = $wgOut; |
315 | 315 | $oldRequest = $wgRequest; |
| 316 | + $oldTitle = $wgTitle; |
316 | 317 | $wgOut = $this->output; |
317 | 318 | $wgRequest = $this->request; |
| 319 | + $wgTitle = $this->title; |
318 | 320 | |
319 | 321 | $hookResult = wfRunHooks( 'LiquidThreadsDoInlineEditForm', |
320 | 322 | array( |
— | — | @@ -336,6 +338,7 @@ |
337 | 339 | |
338 | 340 | $wgOut = $oldOut; |
339 | 341 | $wgRequest = $oldRequest; |
| 342 | + $wgTitle = $oldTitle; |
340 | 343 | |
341 | 344 | $this->output->setArticleBodyOnly( true ); |
342 | 345 | } |
— | — | @@ -354,7 +357,7 @@ |
355 | 358 | $title = $talkpage->getTitle(); |
356 | 359 | } |
357 | 360 | } |
358 | | - |
| 361 | + |
359 | 362 | $request->setVal( 'lqt_method', $method ); |
360 | 363 | $request->setVal( 'lqt_operand', $operand ); |
361 | 364 | |
Index: trunk/extensions/LiquidThreads/api/ApiThreadAction.php |
— | — | @@ -24,7 +24,7 @@ |
25 | 25 | $threads = array( 'all' ); |
26 | 26 | } else { |
27 | 27 | $title = Title::newFromText( $thread ); |
28 | | - $article = new Article( $title ); |
| 28 | + $article = new Article( $title, 0 ); |
29 | 29 | $threadObj = Threads::withRoot( $article ); |
30 | 30 | } |
31 | 31 | |
— | — | @@ -165,7 +165,7 @@ |
166 | 166 | $newParent = Threads::withId( $newParent ); |
167 | 167 | } else { |
168 | 168 | $title = Title::newFromText( $newParent ); |
169 | | - $article = new Article( $title ); |
| 169 | + $article = new Article( $title, 0 ); |
170 | 170 | $newParent = Threads::withRoot( $article ); |
171 | 171 | } |
172 | 172 | |
— | — | @@ -214,7 +214,7 @@ |
215 | 215 | $this->dieUsage( 'The talkpage you specified is invalid, or does not ' . |
216 | 216 | 'have discussion threading enabled.', 'invalid-talkpage' ); |
217 | 217 | } |
218 | | - $talkpage = new Article( $talkpageTitle ); |
| 218 | + $talkpage = new Article( $talkpageTitle, 0 ); |
219 | 219 | |
220 | 220 | // Check if we can post. |
221 | 221 | if ( Thread::canUserPost( $wgUser, $talkpage ) !== true ) { |
— | — | @@ -237,7 +237,7 @@ |
238 | 238 | $this->dieUsage( 'The subject you specified is not valid', |
239 | 239 | 'invalid-subject' ); |
240 | 240 | } |
241 | | - $article = new Article( $title ); |
| 241 | + $article = new Article( $title, 0 ); |
242 | 242 | |
243 | 243 | // Check for text |
244 | 244 | if ( empty( $params['text'] ) ) { |
— | — | @@ -502,7 +502,7 @@ |
503 | 503 | |
504 | 504 | // Generate a reply title. |
505 | 505 | $title = Threads::newReplyTitle( $replyTo, $wgUser ); |
506 | | - $article = new Article( $title ); |
| 506 | + $article = new Article( $title, 0 ); |
507 | 507 | |
508 | 508 | // Inform hooks what we're doing |
509 | 509 | LqtHooks::$editTalkpage = $talkpage; |
— | — | @@ -786,7 +786,7 @@ |
787 | 787 | } |
788 | 788 | |
789 | 789 | if ( $talkpage ) { |
790 | | - $talkpage = new Article( Title::newFromText( $talkpage ) ); |
| 790 | + $talkpage = new Article( Title::newFromText( $talkpage ), 0 ); |
791 | 791 | } else { |
792 | 792 | $talkpage = null; |
793 | 793 | } |