Completed
Push — master ( 2637f1...d5e796 )
by Pieter
02:33
created
src/Events/UnknownEventException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ekinhbayar\GitAmp\Client;
4 4
 
Please login to merge, or discard this patch.
src/Response/DecodingFailedException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ekinhbayar\GitAmp\Client;
4 4
 
Please login to merge, or discard this patch.
src/Response/ResultsIterator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ekinhbayar\GitAmp\Client;
4 4
 
Please login to merge, or discard this patch.
src/Storage/RedisCounter.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ekinhbayar\GitAmp\Storage;
4 4
 
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
     }
27 27
 
28 28
     public function increment(string $key): Promise {
29
-        return resolve(function () use ($key) {
29
+        return resolve(function() use ($key) {
30 30
             try {
31 31
                 return yield $this->redis->incr($key);
32 32
             } catch (RedisException $e) {
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
     }
37 37
 
38 38
     public function decrement(string $key): Promise {
39
-        return resolve(function () use ($key) {
39
+        return resolve(function() use ($key) {
40 40
             try {
41 41
                 return yield $this->redis->eval(self::SCRIPT_DECREMENT, [$key], []);
42 42
             } catch (RedisException $e) {
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
     }
47 47
 
48 48
     public function get(string $key): Promise {
49
-        return resolve(function () use ($key) {
49
+        return resolve(function() use ($key) {
50 50
             try {
51 51
                 $result = yield $this->redis->get($key);
52 52
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     }
59 59
 
60 60
     public function set(string $key, int $val): Promise {
61
-        return resolve(function () use ($key, $val) {
61
+        return resolve(function() use ($key, $val) {
62 62
             try {
63 63
                 return yield $this->redis->set($key, $val);
64 64
             } catch (RedisException $e) {
Please login to merge, or discard this patch.
src/Response/Results.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ekinhbayar\GitAmp\Response;
4 4
 
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 
16 16
     public function __construct(Factory $eventFactory)
17 17
     {
18
-        $this->eventFactory    = $eventFactory;
18
+        $this->eventFactory = $eventFactory;
19 19
     }
20 20
 
21 21
     public function appendResponse(Response $response)
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
     {
36 36
         try {
37 37
             $this->events[] = $this->eventFactory->build($event);
38
-        } catch(UnknownEventException $e) {
38
+        } catch (UnknownEventException $e) {
39 39
             // maybe log unknown events?
40 40
         }
41 41
     }
Please login to merge, or discard this patch.
config-sample.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
         'certificate' => '/path/to/certificate.pem',
33 33
         'key' => '/path/to/key.pem',
34 34
     ],
35
-    */
35
+     */
36 36
     /**
37 37
      * Either use a token or a username + password login.
38 38
      * Note for 2fa users, you can only use tokens.
Please login to merge, or discard this patch.
server.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ekinhbayar\GitAmp\Client;
4 4
 
Please login to merge, or discard this patch.
Braces   +8 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,12 +25,16 @@
 block discarded – undo
25 25
 if (isset($configuration['ssl'])) {
26 26
     $origin = 'https://' . $configuration['hostname'];
27 27
 
28
-    if ($configuration['ssl']['port'] !== 443) $origin .= ':' . $configuration['ssl']['port'];
29
-} else {
28
+    if ($configuration['ssl']['port'] !== 443) {
29
+        $origin .= ':' . $configuration['ssl']['port'];
30
+    }
31
+    } else {
30 32
     $origin = 'http://' . $configuration['hostname'];
31 33
 
32
-    if ($configuration['expose']['port'] !== 80) $origin .= ':' . $configuration['expose']['port'];
33
-}
34
+    if ($configuration['expose']['port'] !== 80) {
35
+        $origin .= ':' . $configuration['expose']['port'];
36
+    }
37
+    }
34 38
 
35 39
 $injector->define(Handler::class, [
36 40
     ':origin' => $origin,
Please login to merge, or discard this patch.