Index: trunk/extensions/LiquidThreads/classes/LqtNewMessages.php |
— | — | @@ -77,9 +77,14 @@ |
78 | 78 | |
79 | 79 | static function newUserMessages( $user ) { |
80 | 80 | global $wgDBprefix; |
| 81 | + |
| 82 | + $talkPage = new Article( $user->getUserPage()->getTalkPage() ); |
81 | 83 | return Threads::where( array( 'ums_read_timestamp is null', |
82 | | - Threads::articleClause( new Article( $user->getUserPage() ) ) ), |
83 | | - array(), array(), "left outer join {$wgDBprefix}user_message_state on ums_user is null or (ums_user = {$user->getID()} and ums_thread = thread.thread_id)" ); |
| 84 | + Threads::articleClause( $talkPage ) ), |
| 85 | + array(), array(), |
| 86 | + "left outer join {$wgDBprefix}user_message_state on " . |
| 87 | + "ums_user is null or ". |
| 88 | + "(ums_user = {$user->getID()} and ums_thread = thread.thread_id)" ); |
84 | 89 | } |
85 | 90 | |
86 | 91 | static function watchedThreadsForUser( $user ) { |
Index: trunk/extensions/LiquidThreads/pages/SpecialNewMessages.php |
— | — | @@ -26,9 +26,12 @@ |
27 | 27 | $this->request = $wgRequest; |
28 | 28 | |
29 | 29 | $this->setHeaders(); |
| 30 | + |
| 31 | + $article = new Article( $this->getTitle() ); |
| 32 | + $title = $this->getTitle(); |
30 | 33 | |
31 | | - $view = new NewUserMessagesView( $this->output, new Article( $this->getTitle() ), |
32 | | - $this->getTitle(), $this->user, $this->request ); |
| 34 | + $view = new NewUserMessagesView( $this->output, $article, |
| 35 | + $title, $this->user, $this->request ); |
33 | 36 | |
34 | 37 | $view->showOnce(); // handles POST etc. |
35 | 38 | |