Index: trunk/phase3/includes/api/ApiQueryUserInfo.php |
— | — | @@ -117,6 +117,10 @@ |
118 | 118 | $vals['ratelimits'] = $this->getRateLimits(); |
119 | 119 | } |
120 | 120 | |
| 121 | + if ( isset( $this->prop['realname'] ) ) { |
| 122 | + $vals['realname'] = $wgUser->getRealName(); |
| 123 | + } |
| 124 | + |
121 | 125 | if ( isset( $this->prop['email'] ) ) { |
122 | 126 | $vals['email'] = $wgUser->getEmail(); |
123 | 127 | $auth = $wgUser->getEmailAuthenticationTimestamp(); |
— | — | @@ -189,6 +193,7 @@ |
190 | 194 | 'editcount', |
191 | 195 | 'ratelimits', |
192 | 196 | 'email', |
| 197 | + 'realname', |
193 | 198 | 'acceptlang', |
194 | 199 | ) |
195 | 200 | ) |
— | — | @@ -207,6 +212,7 @@ |
208 | 213 | ' options - Lists all preferences the current user has set', |
209 | 214 | ' editcount - Adds the current user\'s edit count', |
210 | 215 | ' ratelimits - Lists all rate limits applying to the current user', |
| 216 | + ' realname - Adds the user\'s real name', |
211 | 217 | ' email - Adds the user\'s email address and email authentication date', |
212 | 218 | ' acceptlang - Echoes the Accept-Language header sent by the client in a structured format', |
213 | 219 | ) |
Index: trunk/phase3/RELEASE-NOTES |
— | — | @@ -56,6 +56,7 @@ |
57 | 57 | * (bug 14869) Add API module for accessing QueryPage-based special pages |
58 | 58 | * (bug 14020) API for Special:Unwatchedpages |
59 | 59 | * (bug 24287) Wrap API Help output at 100 characters |
| 60 | +* Add a realname uiprop option to query=userinfo so a user's realname can be extracted |
60 | 61 | |
61 | 62 | === Languages updated in 1.18 === |
62 | 63 | |