Passed
Pull Request — main (#15)
by
unknown
02:21
created
src/Resources/Seasons.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -50,7 +50,7 @@
 block discarded – undo
50 50
             $response = $this->client->get(self::RESOURCE);
51 51
             $data     = json_decode($response->getBody()->getContents(), true);
52 52
 
53
-            return array_map( function(array $season) {
53
+            return array_map(function(array $season) {
54 54
                 return new Season($season);
55 55
             }, $data);
56 56
         } catch (GuzzleException $e) {
Please login to merge, or discard this patch.
src/Interfaces/RequestHandlerInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,5 +23,5 @@
 block discarded – undo
23 23
      * @param array $args
24 24
      * @return array|Exception
25 25
      */
26
-    public function post(string $endpoint, array $args = []): array|Exception;
26
+    public function post(string $endpoint, array $args = []): array | Exception;
27 27
 }
28 28
\ No newline at end of file
Please login to merge, or discard this patch.
src/Resources/Performance.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
     public function description(): string
32 32
     {
33 33
 
34
-        return (string)$this->_extraArgs['PerformanceDescription'];
34
+        return (string) $this->_extraArgs['PerformanceDescription'];
35 35
 
36 36
     }
37 37
 
Please login to merge, or discard this patch.
src/Resources/PriceSummary.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,13 +15,13 @@
 block discarded – undo
15 15
 
16 16
     public function zoneId() : int {
17 17
 
18
-        return intval( $this->_extraArgs['ZoneId'] );
18
+        return intval($this->_extraArgs['ZoneId']);
19 19
 
20 20
     }
21 21
 
22 22
     public function enabled(): bool
23 23
     {
24
-        return (bool)$this->_extraArgs['Enabled'];
24
+        return (bool) $this->_extraArgs['Enabled'];
25 25
     }
26 26
 
27 27
     public function performanceId(): int
Please login to merge, or discard this patch.
src/Resources/Season.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@
 block discarded – undo
26 26
 
27 27
     public function getDescription(): string
28 28
     {
29
-        return (string)$this->extraArgs()['Description'];
29
+        return (string) $this->extraArgs()['Description'];
30 30
     }
31 31
 
32 32
     public function getEndDateTime(string $timezone = 'America/New_York') : ?DateTime
Please login to merge, or discard this patch.
src/Helpers/Api.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
             $cachedResponse = $this->_cache->get($cacheKey);
153 153
             
154 154
             if ($cachedResponse !== null) {
155
-                $this->logEvent('Cache hit for endpoint: ' . $endpoint);
155
+                $this->logEvent('Cache hit for endpoint: '.$endpoint);
156 156
                 return $cachedResponse;
157 157
             }
158 158
         }
@@ -174,7 +174,7 @@  discard block
 block discarded – undo
174 174
             if ($method === 'GET' && $this->_cache) {
175 175
                 $cacheExpiration = $args['cache_expiration'] ?? self::CACHE_EXPIRATION_DEFAULT;
176 176
                 $this->_cache->set($cacheKey, $data, $cacheExpiration);
177
-                $this->logEvent('Cached response for endpoint: ' . $endpoint);
177
+                $this->logEvent('Cached response for endpoint: '.$endpoint);
178 178
             }
179 179
             
180 180
             return $data;
@@ -267,7 +267,7 @@  discard block
 block discarded – undo
267 267
      * @return Exception|mixed[]
268 268
      * @throws GuzzleException
269 269
      */
270
-    public function post(string $endpoint, array $args = []): array|Exception
270
+    public function post(string $endpoint, array $args = []): array | Exception
271 271
     {
272 272
 
273 273
         $args = array_merge($args, array(
@@ -295,7 +295,7 @@  discard block
 block discarded – undo
295 295
             'log' => 'tessitura',
296 296
         ));
297 297
 
298
-        $message = 'Tessitura API: ' . $message;
298
+        $message = 'Tessitura API: '.$message;
299 299
 
300 300
         if ($this->getLogger()) {
301 301
             $this->getLogger()->info($message, $args);
@@ -441,6 +441,6 @@  discard block
 block discarded – undo
441 441
             'args' => $keyArgs
442 442
         ];
443 443
         
444
-        return 'tessitura:' . md5(json_encode($keyData));
444
+        return 'tessitura:'.md5(json_encode($keyData));
445 445
     }
446 446
 }
Please login to merge, or discard this patch.
src/Base/Container.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@
 block discarded – undo
100 100
      */
101 101
     public function has(string $id): bool
102 102
     {
103
-        return isset($this->services[$id]) || method_exists($this, 'create' . ucfirst($id));
103
+        return isset($this->services[$id]) || method_exists($this, 'create'.ucfirst($id));
104 104
     }
105 105
 
106 106
     /**
Please login to merge, or discard this patch.
src/Resources/Performances.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 
28 28
             return $this->getPerformancesBetween($start, $end);
29 29
         } catch (Exception $e) {
30
-            throw new Exception("Unable to get upcoming performances: " . $e->getMessage());
30
+            throw new Exception("Unable to get upcoming performances: ".$e->getMessage());
31 31
         }
32 32
     }
33 33
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
     public function getPerformancesForProductionSeason(int $psId): array
59 59
     {
60 60
         return $this->search([
61
-            'ProductionSeasonIds' => (string)$psId,
61
+            'ProductionSeasonIds' => (string) $psId,
62 62
         ]);
63 63
     }
64 64
 
Please login to merge, or discard this patch.
src/Resources/ProductionSeason.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
     /**
28 28
      * @throws InvalidArgumentException
29 29
      */
30
-    public function first_performance_date(string $timezone = 'America/New_York'): DateTime|bool
30
+    public function first_performance_date(string $timezone = 'America/New_York'): DateTime | bool
31 31
     {
32 32
         try {
33 33
             $timezone = new DateTimeZone($timezone);
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
             try {
40 40
                 return DateTime::createFromFormat(' Y-m-d\TG:i:sp', $date, $timezone);
41 41
             } catch (Exception $e) {
42
-                throw new Exception("Unable to parse FirstPerformanceDate: " . $e->getMessage());
42
+                throw new Exception("Unable to parse FirstPerformanceDate: ".$e->getMessage());
43 43
             }
44 44
         }
45 45
 
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
     /**
50 50
      * @throws InvalidArgumentException
51 51
      */
52
-    public function last_performance_date(string $timezone = 'America/New_York'): DateTime|bool
52
+    public function last_performance_date(string $timezone = 'America/New_York'): DateTime | bool
53 53
     {
54 54
         try {
55 55
             $timezone = new DateTimeZone($timezone);
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
             try {
62 62
                 return DateTime::createFromFormat(' Y-m-d\TG:i:sp', $date, $timezone);
63 63
             } catch (Exception $e) {
64
-                throw new Exception("Unable to parse LastPerformanceDate: " . $e->getMessage());
64
+                throw new Exception("Unable to parse LastPerformanceDate: ".$e->getMessage());
65 65
             }
66 66
         }
67 67
 
Please login to merge, or discard this patch.