From: Bartosz DziewoƄski Date: Sat, 16 Nov 2013 00:17:00 +0000 (+0100) Subject: Watch user page and user talk page by default X-Git-Tag: 1.31.0-rc.0~17600^2 X-Git-Url: http://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/?a=commitdiff_plain;h=c33c39216fba7affb84ebd55086bfa844a4af1e2;p=lhc%2Fweb%2Fwiklou.git Watch user page and user talk page by default When creating a new account, add the newly-created user's userpage and talk page to their watchlist. Bug: 49719 Change-Id: I9359682c890cb9249870a0a78a80a0076ba47f34 --- diff --git a/includes/specials/SpecialUserlogin.php b/includes/specials/SpecialUserlogin.php index 75b4a92047..008ad5df9e 100644 --- a/includes/specials/SpecialUserlogin.php +++ b/includes/specials/SpecialUserlogin.php @@ -507,9 +507,12 @@ class LoginForm extends SpecialPage { $u->setOption( 'rememberpassword', $this->mRemember ? 1 : 0 ); $u->saveSettings(); - # Update user count + // Update user count DeferredUpdates::addUpdate( new SiteStatsUpdate( 0, 0, 0, 0, 1 ) ); + // Watch user's userpage and talk page + $u->addWatch( $u->getUserPage(), WatchedItem::IGNORE_USER_RIGHTS ); + return Status::newGood( $u ); }