Completed
Push — master ( cc41b9...0dfb70 )
by Jorge
01:59
created
src/Adapters/GuzzleMiddleware.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
             return $promise;
34 34
         }
35 35
 
36
-        return $promise->then(function (ResponseInterface $response) use ($serviceName) {
36
+        return $promise->then(function(ResponseInterface $response) use ($serviceName) {
37 37
             $wasSuccessful = $response->getStatusCode() >= 200 && $response->getStatusCode() < 300;
38 38
             if ($wasSuccessful) {
39 39
                 $this->circuitBreaker->reportSuccess($serviceName);
Please login to merge, or discard this patch.
src/APCu/SharedStorageTest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@
 block discarded – undo
72 72
         );
73 73
         $this->assertEquals(
74 74
             "a_value",
75
-            $storage->getStrategyData($strategy->reveal(), self::SERVICE_NAME,"a_key")
75
+            $storage->getStrategyData($strategy->reveal(), self::SERVICE_NAME, "a_key")
76 76
         );
77 77
     }
78 78
 
Please login to merge, or discard this patch.
src/AvailabilityStrategy/TimeBackoff.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -78,7 +78,7 @@
 block discarded – undo
78 78
     private function millisecondsSinceLastAttempt(string $serviceName): int
79 79
     {
80 80
         $lastAttempt = $this->getLastAttemptTime($serviceName);
81
-        return $this->now() - $lastAttempt;
81
+        return $this->now()-$lastAttempt;
82 82
     }
83 83
 
84 84
     private function saveAttempt(string $serviceName, int $attempt)
Please login to merge, or discard this patch.
src/AvailabilityStrategy/InMemoryStorage.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
             $this->strategyData[$strategy->getId()][$serviceName] = [];
38 38
         }
39 39
 
40
-        $this->strategyData[$strategy->getId()][$serviceName][$key] =  $value;
40
+        $this->strategyData[$strategy->getId()][$serviceName][$key] = $value;
41 41
     }
42 42
 
43 43
     public function getStrategyData(
Please login to merge, or discard this patch.
src/AvailabilityStrategy/TimeBackoffTest.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
     public function it_closes_the_circuit_after_timeout()
62 62
     {
63 63
         $this->setFailuresToMaxAllowed();
64
-        $oneSecAndOneMillisecond = floor((microtime(true) * 1000)) - self::BASE_WAIT_TIME - 1;
64
+        $oneSecAndOneMillisecond = floor((microtime(true) * 1000))-self::BASE_WAIT_TIME-1;
65 65
         $this->storage->saveStrategyData(
66 66
             $this->sut,
67 67
             self::SERVICE_NAME,
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
     {
113 113
         $this->storage->setNumberOfFailures(
114 114
             self::SERVICE_NAME,
115
-            self::MAX_FAILURES - 1
115
+            self::MAX_FAILURES-1
116 116
         );
117 117
     }
118 118
 
@@ -124,6 +124,6 @@  discard block
 block discarded – undo
124 124
             $this->sut,
125 125
             self::SERVICE_NAME,
126 126
             self::LAST_ATTEMPT_KEY,
127
-            floor(microtime(true) * 1000) - 1);
127
+            floor(microtime(true) * 1000)-1);
128 128
     }
129 129
 }
Please login to merge, or discard this patch.