Set password to empty string when reloading login form (#158)

This commit is contained in:
Sohel Ahmed Mesaniya 2017-11-16 14:33:46 +05:30 committed by Alexander Makarov
parent 988bfd39df
commit fc82ba48d0

View File

@ -79,6 +79,8 @@ class SiteController extends Controller
if ($model->load(Yii::$app->request->post()) && $model->login()) {
return $this->goBack();
}
$model->password = '';
return $this->render('login', [
'model' => $model,
]);