@@ -73,7 +73,6 @@ discard block |
||
73 | 73 | /** |
74 | 74 | * Constructor. |
75 | 75 | * |
76 | - * @param Database $db |
|
77 | 76 | * @param LoggerInterface $logger |
78 | 77 | */ |
79 | 78 | public function __construct(SocketFactory $factory, LoggerInterface $logger, ?Iterable $config = null) |
@@ -131,7 +130,7 @@ discard block |
||
131 | 130 | * |
132 | 131 | * @param File $file |
133 | 132 | * |
134 | - * @return array |
|
133 | + * @return File |
|
135 | 134 | */ |
136 | 135 | public function scan(File $file): array |
137 | 136 | { |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -101,14 +101,14 @@ discard block |
||
101 | 101 | return [ |
102 | 102 | 'id' => (string) $slave['_id'], |
103 | 103 | 'format' => (string) $slave['format'], |
104 | - 'master' => function ($slave) use ($fs, $node_decorator) { |
|
104 | + 'master' => function($slave) use ($fs, $node_decorator) { |
|
105 | 105 | try { |
106 | 106 | return $node_decorator->decorate($fs->findNodeById($slave['master']), ['_links', 'id', 'name']); |
107 | 107 | } catch (\Exception $e) { |
108 | 108 | return null; |
109 | 109 | } |
110 | 110 | }, |
111 | - 'slave' => function ($slave) use ($fs, $node_decorator) { |
|
111 | + 'slave' => function($slave) use ($fs, $node_decorator) { |
|
112 | 112 | if (!isset($slave['slave'])) { |
113 | 113 | return null; |
114 | 114 | } |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | 'id' => (string) $message['_id'], |
103 | 103 | 'message' => (string) $message['body'], |
104 | 104 | 'subject' => (string) $message['subject'], |
105 | - 'sender' => function ($message) use ($server, $role_decorator) { |
|
105 | + 'sender' => function($message) use ($server, $role_decorator) { |
|
106 | 106 | try { |
107 | 107 | return $role_decorator->decorate($server->getUserById($message['sender']), ['_links', 'id', 'username']); |
108 | 108 | } catch (\Exception $e) { |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | ->prependRoute(new Route('/api/v2/nodes|files|collections/subscription(/|\z)', v2\Subscription::class)) |
36 | 36 | ->prependRoute(new Route('/api/v2/nodes|files|collections/{id:#([0-9a-z]{24})#}/subscription(/|\z)', v2\Subscription::class)); |
37 | 37 | |
38 | - $decorator->addDecorator('subscription', function ($node) use ($server) { |
|
38 | + $decorator->addDecorator('subscription', function($node) use ($server) { |
|
39 | 39 | $subscription = $node->getAppAttribute('Balloon\\App\\Notification', 'subscription'); |
40 | 40 | |
41 | 41 | if (is_array($subscription)) { |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | return false; |
46 | 46 | }); |
47 | 47 | |
48 | - $decorator->addDecorator('subscription_exclude_me', function ($node) use ($server) { |
|
48 | + $decorator->addDecorator('subscription_exclude_me', function($node) use ($server) { |
|
49 | 49 | $subscription = $node->getAppAttribute('Balloon\\App\\Notification', 'subscription'); |
50 | 50 | |
51 | 51 | if (is_array($subscription) && isset($subscription[(string) $server->getIdentity()->getId()]['exclude_me'])) { |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | return false; |
56 | 56 | }); |
57 | 57 | |
58 | - $decorator->addDecorator('subscription_recursive', function ($node) use ($server) { |
|
58 | + $decorator->addDecorator('subscription_recursive', function($node) use ($server) { |
|
59 | 59 | if (!($node instanceof Collection)) { |
60 | 60 | return null; |
61 | 61 | } |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types=1); |
|
3 | +declare(strict_types = 1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * balloon |