@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -62,7 +62,7 @@ discard block |
||
62 | 62 | * @param Session $session |
63 | 63 | * @return void |
64 | 64 | */ |
65 | - public function __construct(User $user, $ttl=3600, ?Session $session=null) |
|
65 | + public function __construct(User $user, $ttl = 3600, ?Session $session = null) |
|
66 | 66 | { |
67 | 67 | $this->user = $user; |
68 | 68 |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -63,12 +63,12 @@ discard block |
||
63 | 63 | * @param string $p |
64 | 64 | * @return Response |
65 | 65 | */ |
66 | - public function post(?string $id=null, ?string $p=null): Response |
|
66 | + public function post(?string $id = null, ?string $p = null) : Response |
|
67 | 67 | { |
68 | 68 | $node = $this->fs->getNode($id, $p, 'File'); |
69 | 69 | $document = new Document($this->fs->getDatabase(), $node); |
70 | 70 | |
71 | - $session= new WopiSession($this->fs, $document, (int)$this->config->apps->Office->config->token_ttl); |
|
71 | + $session = new WopiSession($this->fs, $document, (int)$this->config->apps->Office->config->token_ttl); |
|
72 | 72 | $member = new Member($this->fs->getUser(), (int)$this->config->apps->Office->config->token_ttl); |
73 | 73 | $session->join($member) |
74 | 74 | ->store(); |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | */ |
108 | 108 | public function postJoin(string $id): Response |
109 | 109 | { |
110 | - $session= WopiSession::getSessionById($this->fs, $this->parseId($id)); |
|
110 | + $session = WopiSession::getSessionById($this->fs, $this->parseId($id)); |
|
111 | 111 | $member = new Member($this->fs->getUser(), (int)$this->config->apps->Office->config->token_ttl); |
112 | 112 | $session->join($member) |
113 | 113 | ->store(); |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | * @param string $p |
47 | 47 | * @return Response |
48 | 48 | */ |
49 | - public function get(?string $id=null, ?string $p=null): Response |
|
49 | + public function get(?string $id = null, ?string $p = null) : Response |
|
50 | 50 | { |
51 | 51 | $node = $this->fs->getNode($id, $p, 'File'); |
52 | 52 | $document = new OfficeDoc($this->fs->getDatabase(), $node); |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | * @param int $conflict |
119 | 119 | * @return Response |
120 | 120 | */ |
121 | - public function put(string $name, string $type, ?string $collection=null, array $attributes=[], int $conflict=0): Response |
|
121 | + public function put(string $name, string $type, ?string $collection = null, array $attributes = [], int $conflict = 0) : Response |
|
122 | 122 | { |
123 | 123 | $parent = $this->fs->getNode($collection, null, 'Collection', false, true); |
124 | 124 | $tpl = new Template($type); |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | */ |
35 | 35 | public function __construct(Logger $logger, ?Iterable $config) |
36 | 36 | { |
37 | - $this->logger = $logger; |
|
37 | + $this->logger = $logger; |
|
38 | 38 | $this->setOptions($config); |
39 | 39 | } |
40 | 40 | } |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | * @param array $params |
74 | 74 | * @return void |
75 | 75 | */ |
76 | - public function __construct(string $path, $class, ?string $method=null, array $params=[]) |
|
76 | + public function __construct(string $path, $class, ?string $method = null, array $params = []) |
|
77 | 77 | { |
78 | 78 | $this->setPath($path); |
79 | 79 | $this->setClass($class); |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | */ |
90 | 90 | public function match(): bool |
91 | 91 | { |
92 | - $regex = preg_replace_callback('#({([A-Z0-9a-z]+)\:\#(.+?)\#})|\{(.+?)\}#', function ($match) { |
|
92 | + $regex = preg_replace_callback('#({([A-Z0-9a-z]+)\:\#(.+?)\#})|\{(.+?)\}#', function($match) { |
|
93 | 93 | if (count($match) === 4) { |
94 | 94 | return '(?<'.$match[2].'>'.$match[3].'+)'; |
95 | 95 | } else { |
@@ -118,7 +118,7 @@ discard block |
||
118 | 118 | * @param array $constructor |
119 | 119 | * @return array |
120 | 120 | */ |
121 | - public function getCallable($constructor=[]): array |
|
121 | + public function getCallable($constructor = []): array |
|
122 | 122 | { |
123 | 123 | if (is_object($this->class)) { |
124 | 124 | $instance = $this->class; |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | * @param string $name |
141 | 141 | * @return string |
142 | 142 | */ |
143 | - protected function _buildMethodName(?string $name): string |
|
143 | + protected function _buildMethodName(?string $name) : string |
|
144 | 144 | { |
145 | 145 | $result = $this->router->getVerb(); |
146 | 146 | |
@@ -265,7 +265,7 @@ discard block |
||
265 | 265 | * @param string $method |
266 | 266 | * @return Route |
267 | 267 | */ |
268 | - public function setMethod(?string $method): Route |
|
268 | + public function setMethod(?string $method) : Route |
|
269 | 269 | { |
270 | 270 | $this->method = $method; |
271 | 271 | return $this; |
@@ -313,7 +313,7 @@ discard block |
||
313 | 313 | * @param bool $next |
314 | 314 | * @return Route |
315 | 315 | */ |
316 | - public function continuePropagation($next=true): Route |
|
316 | + public function continuePropagation($next = true): Route |
|
317 | 317 | { |
318 | 318 | $this->continue_propagation = (bool)$next; |
319 | 319 | return $this; |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | * @param Iterable $options |
44 | 44 | * @return AdapterInterface |
45 | 45 | */ |
46 | - public function setOptions(?Iterable $config=null) |
|
46 | + public function setOptions(?Iterable $config = null) |
|
47 | 47 | { |
48 | 48 | parent::setOptions($options); |
49 | 49 |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | * @param Iterable $options |
31 | 31 | * @return void |
32 | 32 | */ |
33 | - public function __construct(?Iterable $config=null); |
|
33 | + public function __construct(?Iterable $config = null); |
|
34 | 34 | |
35 | 35 | |
36 | 36 | /** |
@@ -61,5 +61,5 @@ discard block |
||
61 | 61 | * @param Iterable $options |
62 | 62 | * @return AdapterInterface |
63 | 63 | */ |
64 | - public function setOptions(?Iterable $config=null): AdapterInterface; |
|
64 | + public function setOptions(?Iterable $config = null) : AdapterInterface; |
|
65 | 65 | } |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | * @param Iterable $options |
36 | 36 | * @return AdapterInterface |
37 | 37 | */ |
38 | - public function setOptions(?Iterable $config=null): AdapterInterface |
|
38 | + public function setOptions(?Iterable $config = null) : AdapterInterface |
|
39 | 39 | { |
40 | 40 | parent::setOptions($config); |
41 | 41 | if ($config === null) { |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | /** |
5 | 5 | * Balloon |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | * @param Iterable $options |
53 | 53 | * @return void |
54 | 54 | */ |
55 | - public function __construct(?Iterable $config=null) |
|
55 | + public function __construct(?Iterable $config = null) |
|
56 | 56 | { |
57 | 57 | $this->setOptions($config); |
58 | 58 | } |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | * @param Iterable $options |
96 | 96 | * @return AdapterInterface |
97 | 97 | */ |
98 | - public function setOptions(?Iterable $config=null): AdapterInterface |
|
98 | + public function setOptions(?Iterable $config = null) : AdapterInterface |
|
99 | 99 | { |
100 | 100 | if ($config === null) { |
101 | 101 | return $this; |