Commit f42af951 by Johnny Theill

Fix newlines and missing parameter description

parent 63272f41
<?php
namespace common\models;
use yii\base\Model;
use Yii;
use yii\base\Model;
/**
* Login form
......@@ -44,12 +44,13 @@ class LoginForm extends Model
/**
* Logs in a user using the provided username and password.
*
* @return boolean whether the user is logged in successfully
*/
public function login()
{
if ($this->validate()) {
return Yii::$app->user->login($this->getUser(), $this->rememberMe ? 3600*24*30 : 0);
return Yii::$app->user->login($this->getUser(), $this->rememberMe ? 3600 * 24 * 30 : 0);
} else {
return false;
}
......
......@@ -30,8 +30,8 @@ class User extends ActiveRecord implements IdentityInterface
/**
* Creates a new user
*
* @param $attributes
* @return static|null
* @param array $attributes the attributes given by field => value
* @return static|null the newly created model, or null on failure
*/
public static function create($attributes)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment