r104042 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r104041‎ | r104042 | r104043 >
Date:15:53, 23 November 2011
Author:hashar
Status:ok (Comments)
Tags:
Comment:
User: document 2 returns
Modified paths:
  • /trunk/phase3/includes/User.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/User.php
@@ -393,7 +393,7 @@
394394 * If the code is invalid or has expired, returns NULL.
395395 *
396396 * @param $code String Confirmation code
397 - * @return User
 397+ * @return User object, or null
398398 */
399399 public static function newFromConfirmationCode( $code ) {
400400 $dbr = wfGetDB( DB_SLAVE );
@@ -414,7 +414,7 @@
415415 *
416416 * @param $request WebRequest object to use; $wgRequest will be used if
417417 * ommited.
418 - * @return User
 418+ * @return User object
419419 */
420420 public static function newFromSession( WebRequest $request = null ) {
421421 $user = new User;

Comments

#Comment by Reedy (talk | contribs)   17:17, 23 November 2011

Does doxygen pick it up like that

Or does it need to be @return User|null ?

#Comment by Hashar (talk | contribs)   20:46, 23 November 2011

It just get it as is:

Returns:
User object, or null

Not sure what User|null does though.

#Comment by Reedy (talk | contribs)   20:56, 23 November 2011

| being or, so it's User or null, in a more machine experience format

Status & tagging log