Удалён лишний компонент ApiNormalizer

This commit is contained in:
ErickSkrauch
2016-11-30 20:57:30 +03:00
parent ce18d07ae2
commit 5de6fa91c8
7 changed files with 20 additions and 82 deletions

View File

@@ -53,7 +53,7 @@ class AuthenticationController extends Controller {
if (($result = $model->login()) === false) {
$data = [
'success' => false,
'errors' => $this->normalizeModelErrors($model->getErrors()),
'errors' => $model->getFirstErrors(),
];
if (ArrayHelper::getValue($data['errors'], 'login') === E::ACCOUNT_NOT_ACTIVATED) {
@@ -83,7 +83,7 @@ class AuthenticationController extends Controller {
if ($model->forgotPassword() === false) {
$data = [
'success' => false,
'errors' => $this->normalizeModelErrors($model->getErrors()),
'errors' => $model->getFirstErrors(),
];
if (ArrayHelper::getValue($data['errors'], 'login') === E::RECENTLY_SENT_MESSAGE) {
@@ -119,7 +119,7 @@ class AuthenticationController extends Controller {
if (($result = $model->recoverPassword()) === false) {
return [
'success' => false,
'errors' => $this->normalizeModelErrors($model->getErrors()),
'errors' => $model->getFirstErrors(),
];
}
@@ -134,7 +134,7 @@ class AuthenticationController extends Controller {
if (($result = $model->renew()) === false) {
return [
'success' => false,
'errors' => $this->normalizeModelErrors($model->getErrors()),
'errors' => $model->getFirstErrors(),
];
}