fix formatting
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
<?php
|
||||
|
||||
namespace Da\User\Command;
|
||||
|
||||
use Da\User\Factory\MailFactory;
|
||||
@ -22,15 +23,14 @@ class CreateController extends Controller
|
||||
$mailService = MailFactory::makeWelcomeMailerService($user);
|
||||
|
||||
if ($this->make(UserCreateService::class, [$user, $mailService])->run()) {
|
||||
$this->stdout(Yii::t('user', 'User has been created') . "!\n", Console::FG_GREEN);
|
||||
$this->stdout(Yii::t('user', 'User has been created')."!\n", Console::FG_GREEN);
|
||||
} else {
|
||||
$this->stdout(Yii::t('user', 'Please fix following errors:') . "\n", Console::FG_RED);
|
||||
$this->stdout(Yii::t('user', 'Please fix following errors:')."\n", Console::FG_RED);
|
||||
foreach ($user->errors as $errors) {
|
||||
foreach ($errors as $error) {
|
||||
$this->stdout(' - ' . $error . "\n", Console::FG_RED);
|
||||
$this->stdout(' - '.$error."\n", Console::FG_RED);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user