fix formatting

This commit is contained in:
Antonio Ramirez
2016-12-14 02:50:12 +01:00
parent f3f4b31bb4
commit 3ba01b4674
140 changed files with 512 additions and 523 deletions

View File

@ -1,4 +1,5 @@
<?php
namespace Da\User\Service;
use Da\User\Contracts\ServiceInterface;
@ -30,15 +31,16 @@ class UserBlockService implements ServiceInterface
{
if ($this->model->getIsBlocked()) {
$this->controller->trigger(UserEvent::EVENT_BEFORE_UNBLOCK, $this->event);
$result = (bool)$this->model->updateAttributes(['blocked_at' => null]);
$result = (bool) $this->model->updateAttributes(['blocked_at' => null]);
$this->controller->trigger(UserEvent::EVENT_AFTER_UNBLOCK, $this->event);
} else {
$this->controller->trigger(UserEvent::EVENT_BEFORE_BLOCK, $this->event);
$result = (bool)$this->model->updateAttributes(
$result = (bool) $this->model->updateAttributes(
['blocked_at' => time(), 'auth_key' => $this->securityHelper->generateRandomString()]
);
$this->controller->trigger(UserEvent::EVENT_AFTER_BLOCK, $this->event);
}
return $result;
}
}