@@ -11,7 +11,6 @@ |
||
| 11 | 11 | |
| 12 | 12 | namespace Balloon\Bootstrap; |
| 13 | 13 | |
| 14 | -use Balloon\App; |
|
| 15 | 14 | use Composer\Autoload\ClassLoader as Composer; |
| 16 | 15 | use Micro\Container\Container; |
| 17 | 16 | use Noodlehaus\Config; |
@@ -14,7 +14,6 @@ |
||
| 14 | 14 | use Balloon\Filesystem\Node\File; |
| 15 | 15 | use Balloon\Filesystem\Node\NodeInterface; |
| 16 | 16 | use Balloon\Filesystem\Storage\Adapter\AdapterInterface; |
| 17 | -use Balloon\Filesystem\Storage\Adapter\Gridfs; |
|
| 18 | 17 | use Psr\Log\LoggerInterface; |
| 19 | 18 | |
| 20 | 19 | class Storage |
@@ -75,7 +75,7 @@ |
||
| 75 | 75 | |
| 76 | 76 | $this->logger->info('new group ['.$result.'] created', [ |
| 77 | 77 | 'category' => get_class($this), |
| 78 | - ]); |
|
| 78 | + ]); |
|
| 79 | 79 | |
| 80 | 80 | return true; |
| 81 | 81 | } |
@@ -49,7 +49,7 @@ |
||
| 49 | 49 | 'foreignField' => '_id', |
| 50 | 50 | 'localField' => 'history.storage._id', |
| 51 | 51 | 'as' => 'blob', |
| 52 | - ]], |
|
| 52 | + ]], |
|
| 53 | 53 | ]); |
| 54 | 54 | |
| 55 | 55 | foreach ($cursor as $object) { |
@@ -113,10 +113,10 @@ |
||
| 113 | 113 | $body->addPart($html); |
| 114 | 114 | |
| 115 | 115 | $mail = (new Message()) |
| 116 | - ->setSubject($message->getSubject($receiver)) |
|
| 117 | - ->setBody($body) |
|
| 118 | - ->setTo($address) |
|
| 119 | - ->setEncoding('UTF-8'); |
|
| 116 | + ->setSubject($message->getSubject($receiver)) |
|
| 117 | + ->setBody($body) |
|
| 118 | + ->setTo($address) |
|
| 119 | + ->setEncoding('UTF-8'); |
|
| 120 | 120 | |
| 121 | 121 | if (null === $sender) { |
| 122 | 122 | $mail->setFrom($this->sender_address, $this->sender_name); |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | * Cli. |
| 41 | 41 | * |
| 42 | 42 | * @param LoggerInterface $logger |
| 43 | - * @param Getopt $getopt |
|
| 43 | + * @param GetOpt $getopt |
|
| 44 | 44 | * @param ContainerInterface $container |
| 45 | 45 | */ |
| 46 | 46 | public function __construct(LoggerInterface $logger, GetOpt $getopt, ContainerInterface $container) |
@@ -171,7 +171,7 @@ |
||
| 171 | 171 | */ |
| 172 | 172 | protected function setExceptionHandler(): self |
| 173 | 173 | { |
| 174 | - set_exception_handler(function ($e) { |
|
| 174 | + set_exception_handler(function($e) { |
|
| 175 | 175 | $this->logger->emergency('uncaught exception: '.$e->getMessage(), [ |
| 176 | 176 | 'category' => get_class($this), |
| 177 | 177 | 'exception' => $e, |
@@ -102,13 +102,13 @@ discard block |
||
| 102 | 102 | } |
| 103 | 103 | |
| 104 | 104 | return [ |
| 105 | - 'created' => function ($role) use ($attributes) { |
|
| 105 | + 'created' => function($role) use ($attributes) { |
|
| 106 | 106 | return $attributes['created']->toDateTime()->format('c'); |
| 107 | 107 | }, |
| 108 | - 'changed' => function ($role) use ($attributes) { |
|
| 108 | + 'changed' => function($role) use ($attributes) { |
|
| 109 | 109 | return $attributes['changed']->toDateTime()->format('c'); |
| 110 | 110 | }, |
| 111 | - 'deleted' => function ($role) use ($attributes) { |
|
| 111 | + 'deleted' => function($role) use ($attributes) { |
|
| 112 | 112 | if (false === $attributes['deleted']) { |
| 113 | 113 | return null; |
| 114 | 114 | } |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | 'namespace' => (string) $attributes['namespace'], |
| 163 | 163 | 'mail' => (string) $attributes['mail'], |
| 164 | 164 | 'locale' => (string) $attributes['locale'], |
| 165 | - 'quota' => function ($role) use ($attributes, $user) { |
|
| 165 | + 'quota' => function($role) use ($attributes, $user) { |
|
| 166 | 166 | if ($attributes['_id'] == $user->getId() || $user->isAdmin()) { |
| 167 | 167 | return $role->getQuotaUsage(); |
| 168 | 168 | } |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | |
| 86 | 86 | if ($this->auth->requireOne()) { |
| 87 | 87 | if (!($this->auth->getIdentity()->getAdapter() instanceof AuthNone)) { |
| 88 | - $this->auth->getIdentity()->getAttributeMap()->addMapper('binary', function ($value) { |
|
| 88 | + $this->auth->getIdentity()->getAttributeMap()->addMapper('binary', function($value) { |
|
| 89 | 89 | return new Binary($value, Binary::TYPE_GENERIC); |
| 90 | 90 | }); |
| 91 | 91 | |
@@ -138,7 +138,7 @@ discard block |
||
| 138 | 138 | */ |
| 139 | 139 | protected function setExceptionHandler(): self |
| 140 | 140 | { |
| 141 | - set_exception_handler(function ($e) { |
|
| 141 | + set_exception_handler(function($e) { |
|
| 142 | 142 | $this->logger->emergency('uncaught exception: '.$e->getMessage(), [ |
| 143 | 143 | 'category' => get_class($this), |
| 144 | 144 | 'exception' => $e, |
@@ -42,7 +42,7 @@ |
||
| 42 | 42 | */ |
| 43 | 43 | protected function setErrorHandler(): self |
| 44 | 44 | { |
| 45 | - set_error_handler(function ($severity, $message, $file, $line) { |
|
| 45 | + set_error_handler(function($severity, $message, $file, $line) { |
|
| 46 | 46 | $log = $message.' in '.$file.':'.$line; |
| 47 | 47 | |
| 48 | 48 | switch ($severity) { |